Skip to content

Instantly share code, notes, and snippets.

@zllovesuki
Created June 16, 2014 06:15
Show Gist options
  • Save zllovesuki/3a151151bf5635774d74 to your computer and use it in GitHub Desktop.
Save zllovesuki/3a151151bf5635774d74 to your computer and use it in GitHub Desktop.
/etc/nginx/site-enabled/website1.conf
server {
listen 80;
server_name example.tld;
root /home/dir/web;
access_log /home/dir/var/log/nginx_access.log;
error_log /home/dir/var/log/nginx_error.log error;
location ~ \.php$ {
try_files $uri =404;
fastcgi_pass unix:/home/dir/var/fcgi/php.sock;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param DOCUMENT_ROOT /web;
fastcgi_param SCRIPT_FILENAME /web$fastcgi_script_name;
fastcgi_read_timeout 300;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment