Nginx PHP5 Fast-CGI FreeBSD CURRENT

Patrick Lamaiziere patfbsds+questions at davenulle.org
Sat Sep 8 16:27:35 PDT 2007


Le Sun, 09 Sep 2007 01:38:50 +0300,
OutBackDingo <outbackdingo at gmail.com> a écrit :

> # .php5 sent to php5
>     location ~ .*\.php5$ {

I'm not sure for this expression, i use for .php
     location ~ \.php$ {

>     include /usr/local/etc/nginx/fastcgi_params;
>     fastcgi_pass  127.0.0.1:10005;
>     fastcgi_index index.php;
>     fastcgi_param SCRIPT_FILENAME /$fastcgi_script_name;

You should append the root location of the server:
fastcgi_param
SCRIPT_FILENAME /usr/local/www/nginx$fastcgi_script_name;

> /usr/local/sbin/spawn-fcgi -f /usr/local/bin/php-cgi -a 127.0.0.1 -p
> 9000 -u www

The port should be 10005 for « fastcgi_pass  127.0.0.1:10005; »

Regards.


More information about the freebsd-questions mailing list