Getting to access a internal port inside a running Docker container
Now that we have moved to a mostly Docker-based infrastructure, one of the tricky things is to try and debug things when there is something pear-shaped. It used to be possible to just SSH into the machine with a local port-forward, and then for example access the Elasticsearch server via a handy browser extension to do debugging.
But what to do if your container is running in a Docker Swarm and has no ports forwarded by default? (which is the right thing to do, keep it simple and closed...)
Thanks to stirling help from https://github.com/eelkevdbos here is the solution, and I am writing it up here so I can remember it in future, cause I sure am gonna forget the details...
First thing, create a new docker overlay network that you can use for getting to the container in question:
docker network create foobar