这是我的整个 nginx.conf 文件
worker_processes 1;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 65;
server {
server_name subsonic.domain.com;
location / {
proxy_pass http://localhost:4040/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_pass_request_headers on;
}
}
# server {
# server_name perforce.domain.com;
# location / {
# proxy_pass http://localhost:1666/;
# proxy_set_header Host $host;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_pass_request_headers on;
# }
# }
}
我在 Windows 8 上,如果我取消注释第二个服务器声明,nginx 会立即崩溃。我花了几个小时尝试示例,但不知道为什么它不起作用。请帮忙,谢谢。