From 72f9b29cdec5b63b0f0cd7aaa2f1409eec9dea4c Mon Sep 17 00:00:00 2001 From: Julien Maitrehenry Date: Tue, 10 Apr 2018 13:28:25 -0400 Subject: [PATCH] Add a note on service discovery on swarm --- network/overlay.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/network/overlay.md b/network/overlay.md index f001a351fd..c1a98b99fd 100644 --- a/network/overlay.md +++ b/network/overlay.md @@ -280,6 +280,10 @@ routing on the individual Docker daemon hosts. | `-p 8080:80/udp` | Map UDP port 80 in the container to port 8080 on the overlay network. | | `-p 8080:80/tcp -p 8080:80/udp` | Map TCP port 80 in the container to TCP port 8080 on the overlay network, and map UDP port 80 in the container to UDP port 8080 on the overlay networkt. | +### Container discovery + +For most situations, you should connect to the service name, which is load-balanced and will be handled by all containers ("tasks") backing the service. +If you need to get a list of all tasks backing the service you can do a DNS lookup for tasks.. ## Next steps