Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80;
- server_name example.com;
- root /var/www/example.com;
- autoindex on;
- index index.html index.php;
- client_max_body_size 50m;
- client_body_buffer_size 1024k;
- client_header_buffer_size 2k;
- include php.conf;
- # if you don't like seeing all the errors for missing favicon.ico in root
- location = /favicon.ico { access_log off; log_not_found off; }
- # if you don't like seeing errors for a missing robots.txt in root
- location = /robots.txt { access_log off; log_not_found off; }
- location ~ /system/.* {
- deny all;
- }
- location ~ /application/.* {
- deny all;
- }
- location ~ ^/(dres|js|css|art)/ {
- access_log off;
- expires 7d;
- add_header Cache-Control public;
- try_files $uri $uri/ /index.php?$args;
- }
- # Deny access to .htaccess files,
- # git & svn repositories, etc
- location ~ /(\.ht|\.git|\.svn) {
- deny all;
- }
- location / {
- try_files $uri $uri/ /index.php?$args;
- }
- location /site/ {
- try_files $uri $uri/ /site/index.php?$args;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement