Setup a Docker cluster

At some point when managing a big environment, you might be intrested in having a Docker cluster.
Or like Docker calls it: a Docker swarm.

Creating one is quite well explained on the official Docker site:
https://docs.docker.com/engine/swarm/swarm-tutorial/create-swarm/

But in short:

first you need to initialize the swarm by the command below

docker swarm init --advertise-addr 10.81.70.199

Docker cluster setup 1

To add workers, execute the command you get as feedback (as shown in the above screenshot) on your other servers.
On the manager server, type

docker node ls

to see your nodes successfully added to the swarm

Docker cluster setup 2

To be able to create a cluster, you may want to install Docker on for example three Debian servers.
Click on this article to see how.

You may also like...