Last active
November 14, 2018 05:52
-
-
Save tanftw/c522867b8e406e72e897050dedd05c08 to your computer and use it in GitHub Desktop.
Nginx Vhost WSL
This file contains hidden or 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
server { | |
listen 80; | |
root /var/www/code/wp; | |
index index.php index.html index.htm index.nginx-debian.html; | |
server_name wp.test; | |
location / { | |
try_files $uri $uri/ /index.php?$query_string; | |
} | |
location ~ \.php$ { | |
fastcgi_split_path_info ^(.+\.php)(/.+)$; | |
fastcgi_pass 127.0.0.1:9000; | |
include fastcgi_params; | |
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; | |
fastcgi_param SCRIPT_NAME $fastcgi_script_name; | |
fastcgi_buffering off; | |
} | |
location ~ /\.ht { | |
deny all; | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment