I’ve SSH installed a Python 3.5 application on CentOS along with uwsgi
and nginx
, but after doing a sudo vi /etc/nginx/nginx.conf
to edit the nginx config file as per usual, the response is currently:
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
these are the contents of the /etc/nginx/nginx.conf file:
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
types_hash_max_size 2048;
include /etc/nginx/mime.types;
default_type application/octet-stream;
include /etc/nginx/conf.d/*.conf;
server {
listen [::]:80 default_server;
server_name _;
root /var/www/html/<directory//;
location / {
}
The server is currently showing an nginx error page
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
@dev5
Uhm, but your Nginx has
server_name localhost;
which means it’s only accessible from the server itself. Can you post your entire Nginx site configuration and your entire uWSGI? And I would recommend that you do not have anyserver
blocks in your main Nginx configuration located in/etc/nginx/nginx.conf
Hi @dev5
Can you run
sudo nginx -t
orsudo service nginx configtest
to test your configuration. And then post the last 30 lines from the error log also:/etc/nginx/nginx.conf
file: https://jpst.it/11K8fand ```/etc/init/uwsgi.conf`` config file: https://jpst.it/11K8T
This comment has been deleted