Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80;
- server_name <domain> www.<domain>;
- # auth_basic "Restricted Access";
- # auth_basic_user_file /etc/nginx/account/<domain>.users;
- root /var/www/<domain>/public_html/;
- index index.php index.html index.htm;
- location / {
- try_files $uri $uri/ /index.php?q=$uri&$args;
- }
- # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
- #
- location ~ \.php$ {
- fastcgi_pass unix:/var/run/php5-fpm.sock;
- fastcgi_index index.php;
- fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
- include fastcgi_params;
- fastcgi_buffer_size 128k;
- fastcgi_buffers 256 4k;
- fastcgi_busy_buffers_size 256k;
- fastcgi_temp_file_write_size 256k;
- }
- # deny access to .htaccess files, if Apache's document root
- # concurs with nginx's one
- #
- location ~ /\.ht {
- deny all;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement