Report this

What is the reason for this report?

Django Deployment - Unable to access django app using my ip ?

Posted on March 1, 2017

I have followed https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-django-with-postgres-nginx-and-gunicorn tutorial to deploy django app. At the end of it, when i tried accessing I got “502 Bad Gateway”.

Here are nginx error logs from error.logs file.

2017/03/01 06:40:13 [error] 26234#26234: *16 connect() failed (111: Connection refused) while connecting to upstream, client: 85.203.18.254, server: 174.138.68.184, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:8001/", host: "174.138.68.184"


2017/03/01 06:41:00 [error] 26301#26301: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 85.203.18.254, server: 174.138.68.184, request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:8001/", host: "174.138.68.184"

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Start building today

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.