Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80;
- root /var/www/html;
- index index.php index.html index.htm;
- server_name tasteaholics.com www.tasteaholics.com;
- location / {
- try_files $uri $uri/ /index.php?q=$uri&$args;
- }
- location ~ \.php$ {
- try_files $uri =404;
- fastcgi_split_path_info ^(.+\.php)(/.+)$;
- fastcgi_cache microcache;
- fastcgi_cache_key $scheme$host$request_uri$request_method;
- fastcgi_cache_valid 200 301 302 30s;
- fastcgi_cache_use_stale updating error timeout invalid_header http_500;
- fastcgi_pass_header Set-Cookie;
- fastcgi_pass_header Cookie;
- fastcgi_ignore_headers Cache-Control Expires Set-Cookie;
- #fastcgi_pass 127.0.0.1:9000;
- fastcgi_pass unix:/var/run/php5-fpm.sock;
- fastcgi_index index.php;
- include fastcgi_params;
- }
- location = /favicon.ico {
- log_not_found off;
- access_log off;
- }
- location ~* .(jpg|jpeg|png|gif|ico|css|js)$ {
- expires 1d;
- }
- include /var/www/html/nginx.conf;
- location = /nginx.conf { deny all; }
- location = /robots.txt {
- allow all;
- log_not_found off;
- access_log off;
- }
- location ~ /\. {
- deny all;
- }
- location ~* /(?:uploads|files)/.*\.php$ {
- deny all;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement