Access to docker-machine from local network


i’m using for a school project Docker CE and docker-machine.
At this time, i’ve set up a VM on my school ESXi server with the ip address (and also a firewall VM).
On that VM, I installed Docker and created 2 docker-machines with the appropriate command line (leader and worker1). I also initialized swarm on the leader node and put the worker node in it.

Now, i deployed by using docker stack deploy my different services and it works find. My problem is that i can’t access to my services from my firewall in the ESXi server.

From my docker host VM, i can access to my services by using curl which is the port of the visualizer container but when i use the same command line from the firewall VM (curl, i have the connexion refused message.

I already tried to use
VBoxManage controlvm "leader" natpf1 "visualizer,tcp,,8080,,8080"
and also NAT rules like
sudo iptables -t nat -A PREROUTING -p tcp -i ens160 -d --dport 8080 -j DNAT --to
on the docker host ( but nothing work at all.

Can anyone please help me with it? I’m totally blocked and this is the last part of my project.

Thank you all :slight_smile:

Solved :slight_smile: