My container runs a TCP socket server which listens to commands on port 6000.
Now i launch this same container as a swarm service with multiple replicas.
Somehow, I want all the containers in the service to be able to receive the commands simultaneously at their internal port 6000, when I make a tcp connection from outside.
But when i connect to the host using :6000, only one container at any time receives the commands.
I created the swarm with 2 replicas:
docker service create
I see my 2 containers are launched correctly on the 2 hosts.
But only one of them gets my commands.