Apologies if this obvious - I can't seem to figure this out. I have a docker container with ports 8112 exposed to the host. Docker ps shows: '>8112/tcp '

From the host, I can successfully connect to the port using localhost: ' curl localhost:8112 **This works '

From the host or remote machine, I cannot connect via ip: ' curl **This fails - just hangs and eventually timeouts '

I'm not sure how to diagnose from here - any help would be greatly appreciated!

  • tcpdump is the way to diagnose this, and perhaps netfilter's TRACE target.
    – womble
    Sep 30, 2019 at 2:54
  • Thank you - will read up on that. Is there anything I should be looking for specifically?
    – frootloop
    Oct 1, 2019 at 1:48

1 Answer 1


This is likely due to known limitations of Docker networking.

From the link: "Per-container IP addressing is not possible"

Link is for Mac, as that is what I use, but I think there may be a similar limitation with Docker for Windows.

This is likely why you are able to access the container from localhost, but not by its IP.

EDIT: This all applies to connecting to the container from the host, if you want to connect to it remotely there are a bunch of other factors like firewalls that have nothing to do with Docker and might prevent you from accessing.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .