我正在尝试使用Nginx在AWS EC2实例上部署Django网站。我收到以下错误。
*1 connect() failed (111: Connection refused) while connecting to upstream, client: **.***.***.***, , server: **.**.***.*, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:8000/", host: "*.amazonaws.com"
在/etc/nginx/sites-available
文件夹中,我有一个具有以下配置的文件
server{
listen 80;
server_name your_public_ip;
location = /favicon.ico { access_log off; log_not_found off; }
location /static/ {
root /home/ubuntu/mySiteFolder;
}
location / {
include proxy_params;
proxy_pass http://127.0.0.1:8000;
}
}
我犯的错误在哪里?预先谢谢你。