Getting the error:
nginx: [emerg] "proxy_pass" directive is duplicate in /etc/nginx/sites-enabled/mhprints:12
nginx: configuration file /etc/nginx/nginx.conf test failed
when trying to run my django project on nginx and gunicorn.
my settings in folder error points to:
server {
listen 80;
server_name 194.146.49.249;
location = /favicon.ico { access_log off; log_not_found off; }
location /static/ {
root /home/dave/mhprints;
}
location / {
include proxy_params;
proxy_pass http://unix:/run/gunicorn.sock;
}
}
Can't find a fix, hoping somebody knows on here.
Solved, used the following command:
sudo grep -ri 'proxy_pass' /etc/nginx/
Found the duplicate and deleted it.