Swarm 1.12 rc4 name resolution

I have a 3 node swarm cluster (Docker version 1.12.0-rc4, build e4a0dbc)

1 master
2 workers

I have 2 containers I am launching

docker network create -d overlay myapp
docker service create --name app1 --replicas 1 --network myapp --publish 8080 myapp --peer=app2
docker service create --name app2 --replicas 1 --network myapp --publish 8080 myapp --peer=app1

app1 and app2 can not seem to find eachother. The names are not resolving


Similar post with the way I got it working - Swam 1.12 Multi-host networking help

I don’t know what --peer parameter is for. In build service discovery should do the trick. You can try to attach a process(/bin/bash) to running container lets say app1 and try to do curl http://app2:8080, ideally it should resolve. For some reason ping just don’t work.

those are params to my container that tell it the hostname to connect to of its peer, those names do not resolve