Created
April 29, 2012 13:23
-
-
Save ipedrazas/2550426 to your computer and use it in GitHub Desktop.
Nginx Server config
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
server { | |
listen 80 default; | |
root /var/www/blibb/php/public; | |
index index.php; | |
location /user/ { | |
try_files $uri $uri/ /main.php?id=$uri&$args; | |
} | |
location / { | |
try_files $uri $uri/ $uri.php?$args; | |
} | |
location ~ \.php$ { | |
fastcgi_pass 127.0.0.1:9000; | |
include /etc/nginx/fastcgi_params; | |
} | |
location ~ \.(aspx|jsp|cgi)$ { | |
return 410; | |
} | |
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { | |
expires max; | |
log_not_found off; | |
} | |
location = /favicon.ico { | |
log_not_found off; | |
access_log off; | |
} | |
location = /robots.txt { | |
allow all; | |
log_not_found off; | |
access_log off; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment