Skip to content

Instantly share code, notes, and snippets.

@theel0ja
Created February 13, 2019 06:33
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save theel0ja/7f13c1aa18eaa2e363265b8d261a91ad to your computer and use it in GitHub Desktop.
/etc/nginx/sites-available/pi.hole
server {
listen 80;
listen [::]:80;
server_name pi.hole;
allow 192.0.2.15;
deny all;
root /var/www/html;
# Add index.php to the list if you are using PHP
index index.php index.html;
location / {
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404.
try_files $uri $uri/ =404;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
}
}
@theel0ja
Copy link
Author

Used on Raspbian GNU/Linux 9.6 (stretch)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment