From windows to docker on Linux Host


I have been struggling with the following problem.

Computer 1: Windows machine with Network interface set to
Computer 2: Linux machine with eth0 interface set to
Computer 2: Docker image running with --network host

I would like to be able to, for example, ssh into the docker running in the Linux machine

When I am in the docker I can ping the windows machine (ping However, the docker does not have an IP address as far as I can tell as I don’t see any assigned when I do

docker inspect <image id>

I tried to follow some instructions such as create a new docker network

docker network create --subnet= mynet

with the intention to then run the docker using that network

docker run -it --network mynet <image name>

but this messed up everything. I was not able to ping the Linux machine from windows

Any suggestion?