Nginx, django, gunicorn, ubuntu 14.04 (13: Permission denied) while connecting to upstream Nginx, django, gunicorn, ubuntu 14.04 (13: Permission denied) while connecting to upstream nginx nginx

Nginx, django, gunicorn, ubuntu 14.04 (13: Permission denied) while connecting to upstream


proxy_pass http://unix:/root/myproject/myproject.sock;

The socket is in the superuser's home folder. That's pretty much inaccessible to all other users including your nginx users. Please more the socket to a different location. /var/log/gunicorn/ is a good place.

Also do i see you running gunicorn as root?. Not recommended.

setuid root

Please use some other user here.


I think you have some other process using port 80, according to your nginx error log.

You'll have to figure out what that process is, and kill it if unneeded. Or use another port.