Comment on Listmonk email server, running via docker through nginx vhost. Resolves with port at the end but I get a 502 bad gateway error without the port.

<- View Parent
brygphilomena@lemmy.world ⁨7⁩ ⁨months⁩ ago

Not the docker container IP. The IP of the machine you are running docker itself on. Nginx is running in a container, it’s not allowed to talk to the other docker container IP directly and it has a separate network stack from the listmonk container, so 127.0.0.1 only goes back to nginx.

Say your machine that you are running docker on is 192.168.0.67, the listmonk docker container is 172.16.0.89, and nginx container has an IP of 172.16.0.34.

Your nginx config would need the proxy to point to 192.168.0.67:5870.

Then make sure you don’t have ufw or some similar firewall blocking the connection from nginx to listmonk.

source
Sort:hotnewtop