【发布时间】:2019-01-06 04:10:06
【问题描述】:
nginx: [emerg] invalid number of arguments in "proxy_pass" directive in /etc/nginx/sites-enabled/django_direct:12
我的 nginx 配置文件:
server {
listen 80;
server_name 94.154.13.214;
location = /favicon.ico { access_log off; log_not_found off; }
location /static/ {
root /root/django_direct/main_app/;
}
location / {
include proxy_params;
proxy_pass unix: /root/django_direct/django_direct.sock;
}
}
我该怎么办? 更新: 我已经更改了这样的文件:
proxy_pass http://unix:/root/django_direct/django_direct.sock;
但没有帮助,我已经重新启动了 nginx,现在 我现在收到 502 Bad Gateway 错误。
【问题讨论】:
-
unix:在这里做什么?这不应该是一条路吗? -
你在 unix: 和路径的其余部分之间有一个额外的剃须。
-
@DanielRoseman 查看更新
-
@user2950593:你得到完全相同的错误?
-
@user2950593:你重启了nginx服务器了吗?