Last active
July 14, 2021 14:38
-
-
Save sitemapxml/34fbe77218884467e7767ccec9a61169 to your computer and use it in GitHub Desktop.
Sample nginx config used in USet script (@sitemapxml/uset)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# You can download this file and copy to sites-available | |
# You can also change file name | |
# To activate configuration you should make symlink sites-enabled | |
# Install instructions: | |
# wget https://gist.githubusercontent.com/sitemapxml/34fbe77218884467e7767ccec9a61169/raw/a6bf47e6bb93ab87dba3d061dd866d3aa20f4a92/nginx-sample.conf | |
# cp ./nginx-sample.conf /etc/nginx/sites-available/nginx-sample.conf | |
# ln -s ./nginx-sample.conf /etc/nginx/sites-enabled/nginx-sample.conf | |
server { | |
listen 80 default_server; | |
listen [::]:80 default_server; | |
root /var/www/dir_default/html; | |
index index.php index.html index.htm; | |
server_name sn_default; | |
location / { | |
try_files $uri $uri/ =404; | |
} | |
location ~ \.php$ { | |
include snippets/fastcgi-php.conf; | |
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; | |
} | |
location ~ /\.ht { | |
deny all; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment