nginx: [emerg] open() "/etc/nginx/fastcgi.conf" failed
Posted on 2021-01-13 16:54 陈达辉 阅读(1663) 评论(0) 编辑 收藏 举报报这个错误,是因为nginx版本的 fastcgi.conf 文件不见了,变成了 fastcgi_params
查看官方文档示例
server {
listen 80;
server_name example.org www.example.org;
root /data/www;
location / {
index index.html index.php;
}
location ~* \.(gif|jpg|png)$ {
expires 30d;
}
location ~ \.php$ {
fastcgi_pass localhost:9000;
fastcgi_param SCRIPT_FILENAME
$document_root$fastcgi_script_name;
include fastcgi_params;
}
}