Hey, I followed the exact same steps but I am getting this error after I host it with nginx
12:10:20 [crit] 142389#142389: *1 connect() to unix:/root/status_report_automation/status_report_automation.sock failed (13: Permission denied) while connecting to upstream, client: 103.99.218.187, server: _, request: "GET / HTTP/1.1", upstream: upstream: "unix:/root/status_report_automatio...", host: ":8080"
Nginx is listening to port 8080
Hey, I followed the exact same steps but I am getting this error after I host it with nginx
12:10:20 [crit] 142389#142389: *1 connect() to unix:/root/status_report_automation/status_report_automation.sock failed (13: Permission denied) while connecting to upstream, client: 103.99.218.187, server: _, request: "GET / HTTP/1.1", upstream: upstream: "unix:/root/status_report_automatio...", host: ":8080"
Nginx is listening to port 8080
It looks like you have put your project in the
/root
directory.It is better to put it in
/var/www/
like this:Then set the correct permissions on the directory and files.
Make sure your systemd service file looks something like this in the service section: