Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80;
- server_name sitename.com www.sitename.com;
- location /blog {
- root /www/sitename/new/htdocs/blog;
- fastcgi_index index.php;
- fastcgi_pass 127.0.0.1:9000;
- fastcgi_param SCRIPT_FILENAME /www/sitename/new/htdocs/blog$fastcgi_script_name;
- error_log /www/sitename/new/blog-error.log warn;
- }
- location / {
- root /www/sitename/new/htdocs;
- index index.php;
- if (-f $request_filename) {
- break;
- }
- if (!-f $request_filename) {
- rewrite ^/(.*)$ /index.php?$1 last;
- break;
- }
- error_log /www/sitename/new/error.log warn;
- }
- location ~ \.php$ {
- set $php_root /www/sitename/new/htdocs;
- fastcgi_pass 127.0.0.1:9000;
- fastcgi_index index.php;
- fastcgi_param SCRIPT_FILENAME $php_root$fastcgi_script_name;
- include fastcgi_params;
- }
- # deny access to apache .htaccess files
- location ~ /\.ht
- {
- deny all;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement