配置ngnix

server {
        listen 80;
        server_name     www.aaa.com;
        root    /home/www/...;
        index   index.php index.html index.htm;

        location ~ .php/ {
                if ($request_uri ~ ^(.+.php)(/.+?)($|?)) { }
                fastcgi_pass 127.0.0.1:9000;
                include fastcgi_params;
                fastcgi_param SCRIPT_NAME     $1;
                fastcgi_param PATH_INFO       $2;
                fastcgi_param SCRIPT_FILENAME $document_root$1;
        }
        location ~ .php$ {
                fastcgi_pass 127.0.0.1:9000;
                fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
                include fastcgi_params;
        }

        access_log      /home/www/wwwlogs/www_aaa_com_access.log  access;
        error_log       /home/www/wwwlogs/www_aaa_com_error.log;

}
原文地址:https://www.cnblogs.com/wicub/p/6145693.html