I have Ubuntu server that I am serving Django project. But I can not browse anything. I get ERR_CONNECTION_REFUSED
error on all browsers.
Server host, OS, and applications:
- Digital Ocean Ubuntu 18.04 (LTS) x64
- nginx version: nginx/1.14.0 (Ubuntu)
- ufw 0.36
Here is my nginx and ufw configs:
$ systemctl status nginx
● nginx.service - A high performance web server and a reverse proxy server
Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset: enabled
Active: active (running) since Thu 2021-03-25 11:31:11 UTC; 5h 21min ago
Docs: man:nginx(8) Main PID: 18638 (nginx)
Tasks: 2 (limit: 1152) CGroup: /system.slice/nginx.service
├─18638 nginx: master process /usr/sbin/nginx -g daemon on; master_pr
└─18643 nginx: worker process
$ sudo ufw status
Nginx Full ALLOW Anywhere
22/tcp ALLOW Anywhere
Nginx HTTP ALLOW Anywhere
80/tcp ALLOW Anywhere
443/tcp ALLOW Anywhere
21/tcp ALLOW Anywhere
25/tcp ALLOW Anywhere
Nginx Full (v6) ALLOW Anywhere (v6)
22/tcp (v6) ALLOW Anywhere (v6)
Nginx HTTP (v6) ALLOW Anywhere (v6)
80/tcp (v6) ALLOW Anywhere (v6)
443/tcp (v6) ALLOW Anywhere (v6)
21/tcp (v6) ALLOW Anywhere (v6)
25/tcp (v6) ALLOW Anywhere (v6)
nginx site-enabled config file
server {
listen 80;
server_name 188.166.117.124;
location = /favicon.ico { access_log off; log_not_found off; }
location /static/ {
root /home/ahubelkis/personal_web_site/personal_web_site;
}
location /media/ {
root /home/ahubelkis/personal_web_site/personal_web_site;
}
location / {
include /etc/nginx/proxy_params;
proxy_pass http://unix:/home/ahubelkis/personal_web_site/personal_web_site/personal_web_site.sock;
}
}
$ sudo systemctl restart nginx
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
What is the problem of my configs.