server {
listen 80;
server_name www.domain.com;
location ~ \.php$ {
root /var/www/html/www/test/public;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
location / {
root /var/www/html/www/;
index index.php;
}
}
docker映射window本地文件夹的nginx的虚拟主机配置文件vhost.nginx.conf
最新推荐文章于 2025-05-24 14:41:11 发布
本文介绍了一个具体的Nginx服务器配置案例,详细展示了如何通过Nginx配置文件实现对特定域名下PHP应用的支持,包括监听端口、指定根目录、设置FastCGI参数等关键配置。
2075

被折叠的 条评论
为什么被折叠?



