Docker Community Forums

Share and learn in the Docker community.

One node swarm: services doesn't respond on tcp port


(Bruno Bigras) #1

I would like to use Swarm with only one node to do rolling updates but I even if I can connect to a service’s port, the service doesn’t respond.

I created a swarm with docker swarm init --listen-addr <my_lan_ip> --advertise-addr <my_lan_ip>.

If I run redis normally (docker run -it --rm -p 6379:6379 redis), the port is open and redis responds when I send ‘INFO’.

If I run redis as a service (docker service create -p 6379:6379 --name redis redis), the port is open but redis doesn’t respond.

Am I doing something wrong or is it a bug?

$ docker version
Client:
Version: 1.12.3
API version: 1.24
Go version: go1.7.3
Git commit: 6b644ec
Built: Thu Oct 27 19:42:59 2016
OS/Arch: linux/amd64

Server:
Version: 1.12.3
API version: 1.24
Go version: go1.7.3
Git commit: 6b644ec
Built: Thu Oct 27 19:42:59 2016
OS/Arch: linux/amd64

arch linux