Not able to connect to the container

Hi Team,

I am not able to connect to container if I curl from the jump server . Pls find attached the screen shot . Kindly help resolve .

Regards, Pranav


As always: please include the full name of the lab you’re doing, so we can find it. Thanks!

Just missed to mention that the issue I am facing is from Day 41 Lab of “100 Days of Devops” .

Not clear to me why you’d expect you’d have something to connect to. The task involves creating a Dockerfile. But:

  • You haven’t actually created a Docker image from that Dockerfile, and
  • You haven’t run a container that is based on such an image, and
  • You haven’t bound any ports from that container in such a way that you could reach it from the jump host.

So I’m a little confused, TBH :slight_smile:

OK, I see that you’re doing docker run, so I’d guess you built the image at some point. But note that port 8080 is not open on jump host, so you need to bind it to some other port in order to have that work – note the error you’re getting when you try “run”.

Just tried starting up the image and running it: this will work if you do it right, since it worked for me.