From Apache to Nginx+php-fpm : How to port configuration ?
ftrudeau
nginx-forum at nginx.us
Sun Nov 1 21:26:52 MSK 2009
Found the solution.
Hope this helps someone else.
[...]
# Handle PHP scripts via fastcgi
location ~ ^.+\.php$
{
# set document root
root ;
# test for file existence
# fallback to bootstrap to display 404
try_files $uri /index.php?$args;
# fastcgi setup
fastcgi_pass 127.0.0.1:9000;
# fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
# include common fastcgi params
include /etc/nginx/fastcgi_params;
}
[...]
Posted at Nginx Forum: http://forum.nginx.org/read.php?2,18743,18959#msg-18959
More information about the nginx
mailing list