server { listen 80; server_name yoursite.com; access_log /var/log/nginx/yoursite.com_access.log; error_log /var/log/nginx/yoursite.com_error.log debug; root /var/www/vhosts/yoursite.com; index index.php; include /var/www/vhosts/yoursite.com/nginx.conf; if (!-e $request_filename) { rewrite (.*) /index.php last; } location ~ .php$ { fastcgi_index index.php; fastcgi_pass 127.0.0.1:9000; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } }