[Solved] Connection Refused after initial setup (Ubuntu 18.04)

Hi, I’m new to diaspora (also Ruby on Rails), and I wanted to set up a pod, but I’m having some trouble getting it to work. Specifically, I get a ‘connection refused’ message when clients attempt to connect, and open port check tools say that the port is closed.

I am using a server with a freshly installed Ubuntu 18.04, nginx, and postgres, and otherwise sticking to the steps in the wiki guide for Ubuntu 16.04. My iptables were empty, but I went ahead and enabled ufw and added explicit allow rules for all ports remotely relevant then restarted the services (no change). My server is sitting behind a router, and it has port forwarding set up for port 443 (also my ssh port, which is fine). I used tcpdump to monitor incoming connections on port 443, and I can indeed see them reaching the server.

I don’t see anything in the server logs (checked /var/log/nginx/ and diaspora/logs). No new entries for any attempted connections. I confirmed that both nginx and scripts/server are running without errors. I tried listing the ports where a service was listening, and saw nginx as expected ( lsof -i -P -n | grep LISTEN

It’s like the server is just ignoring the requests for some reason. I’m not sure what the next step is to troubleshoot this. Can anyone help?


EDIT: I figured it out with the help of someone! The nginx configuration file was only listening on ipv6, and not ipv4. Apparently the nginx configuration file at : https://gist.github.com/jhass/1355430 , as linked in the wiki, doesn’t listen on ipv4 with current nginx. Specifically, this listen directive:
listen [::]:443 ssl;
is ipv6 only, which is what was causing me problems.

Someone has already asked me for my configuration, so I am posting it here for posterity: https://pastebin.com/AWsHGVT3