Skip to main content

Posts

Showing posts from May, 2018

DOCKER SWARM WALKTHROUGH

Swarm is native clustering for the docker. When docker engine runs in swarm mode, to manage cluster state manager node implement the Raft Consensus Algorithm. In this article we will setup one manager node and 3 worker nodes which are separate virtual machines running in AWS. Pre-Requisites: > Docker installed and running on all instances.                           > Static IP for all instances                           > Network connectivity between all instances                           > Ports 2377 (network communications),7946(swarm node communication),4789(overlay network) should be open. First go to our manager node.Now to check whether swarm is active or not #docker system info | grep Swarm Now to initialize # docker swarm init or else we can also give #docker swarm init --adverstise-addr ip-of-managernode To list the nodes #docker node ls We can see only one manager node is there which is the leader.(Note: We can also run multiple manager nodes