-2

I am trying to set up a digital ocean server using this tutorial https://www.digitalocean.com/community/tutorials/how-to-set-up-django-with-postgres-nginx-and-gunicorn-on-ubuntu-16-04

The site is served just fine over HTTP but will not load from https. (will not load references this chrome error)

This site can’t be reached kronoswebsolutions.com took too long to respond.
Try:

Checking the connection
Checking the proxy and the firewall
ERR_CONNECTION_TIMED_OUT

As advised I did check the firewall previous to posting but here is the output of my ufw. I do not have a firewall enabled on my digital ocean droplet web gui.

Nginx Full                 ALLOW       Anywhere                  
22                         ALLOW       *************             
22                         ALLOW       *************             
OpenSSH                    ALLOW       Anywhere                  
Nginx Full (v6)            ALLOW       Anywhere (v6)             
OpenSSH (v6)               ALLOW       Anywhere (v6)     
Here is the results of nmap from my local machine using the ip of my server...

nmap -Pn -p 443 IPADDRESS
Starting Nmap 7.70 ( https://nmap.org ) at 2019-05-07 23:46 MDT
Nmap scan report for IPADDRESS
Host is up.

PORT    STATE    SERVICE
443/tcp filtered https

I am using Debian stretch rather than Ubuntu.

  • "Will not load" is, to put it mildly, an uninformative problem description. – womble May 8 at 2:47
  • Is this still to vague or are the edits I provided any help? – Baker Web Solutions May 8 at 3:12
  • 1
    It's understandable now, but you really do need to do what it advised: check the firewall. – Michael Hampton May 8 at 3:13
  • I posted the ufw rules of my server – Baker Web Solutions May 8 at 3:16
  • The ufw rules look fine. But if you disable ufw and reboot, can you then get in? – Michael Hampton May 8 at 3:39
0

Looks like it was definitely a firewall issue. I used this to reset my firewalls settings in iptables then set ufw up again and it is working.

First, set the default policies for each of the built-in chains to ACCEPT. The main reason to do this is to ensure that you won't be locked out from your server via SSH:

$ sudo iptables -P INPUT ACCEPT
$ sudo iptables -P FORWARD ACCEPT
$ sudo iptables -P OUTPUT ACCEPT

Then flush the nat and mangle tables, flush all chains (-F), and delete all non-default chains (-X):

$ sudo iptables -t nat -F
$ sudo iptables -t mangle -F
$ sudo iptables -F
$ sudo iptables -X

Then re enable ufw

$ sudo ufw enable
  • Please accept your own answer as the correct solution. – Tommiie May 8 at 6:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.