From ad29a45191bde4924ffe40ad191b7c15c7b8085c Mon Sep 17 00:00:00 2001 From: Jerome Petazzoni Date: Tue, 1 Nov 2016 17:10:36 -0700 Subject: [PATCH] Add advertise-addr info + small fixups for mentor week --- docs/index.html | 57 +++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 53 insertions(+), 4 deletions(-) diff --git a/docs/index.html b/docs/index.html index 06b6833d..0e1ce98b 100644 --- a/docs/index.html +++ b/docs/index.html @@ -97,7 +97,7 @@ class: title Docker
Orchestration
Workshop ---- +??? ## Intros @@ -117,7 +117,7 @@ on time, it's a good idea to have a breakfast with the attendees at e.g. 9am, and start at 9:30. --> ---- +??? ## Agenda @@ -191,8 +191,6 @@ grep '^# ' index.html | grep -v ' + (i.e. it tells them *"you can contact me on 10.1.2.3:2377"*) + +- If the node has only one IP address (other than 127.0.0.1), it is used automatically + +- If the node has multiple IP addresses, you **must** specify which one to use +
+ (Docker refuses to pick one randomly) + +- You can specify an IP address or an interface name +
(in the latter case, Docker will read the IP address of the interface and use it) + +- You can also specify a port number +
(otherwise, the default port 2377 will be used) + +--- + +## Which IP address should be advertised? + +- If your nodes have only one IP address, it's safe to let autodetection do the job + + .small[(Except if your instances have different private and public addresses, e.g. + on EC2, and you are building a Swarm involving nodes inside and outside the + private network: then you should advertise the public address.)] + +- If your nodes have multiple IP addresses, pick an address which is reachable + *by every other node* of the Swarm + +- If you are using [play-with-docker](http://play-with-docker.com/), use the IP + address shown next to the node name + + .small[(This is the address of your node on your private internal overlay network. + The other address that you might see is the address of your node on the + `docker_gwbridge` network, which is used for outbound traffic.)] + +Examples: + +```bash +docker swarm init --advertise-addr 10.0.9.2 +docker swarm init --advertise-addr eth0:23777 +``` + --- ## Token generation @@ -4645,7 +4692,9 @@ class: title ## [@jpetazzo](https://twitter.com/jpetazzo)
[@docker](https://twitter.com/docker) --> +