skip to Main Content

I’m currently trying to run my application on production with docker on a VPS with Ubuntu 22 installed.

But I can’t access the application, every time I get a timeout on the port that I’ve set.

So I tried the most simple docker image to test what going wrong and even the simple nginx image gives me the same result.

On my PC everything is working great:
enter image description here

But on my VPS it’s not working at all:
enter image description here

And I’ve tried to remove the docker container and then call the localhost again and I get a connection refused, which means that there is nothing running on it.
enter image description here

I’ve tried a lot of thing like uninstall Docker and install it again, forcing the IP to 0.0.0.0 or 127.0.0.1 etc

2

Answers


  1. Most likely you have the same port, try changing to -p 8080:80

    Login or Signup to reply.
  2. Probably you could try removing the -d flag and up the docker using the mentioned command. And can simply go through the error logs 🙂 [error messages are damn cool to have, than having a unusually tidy output]

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search