Docker Swam
Docker Swam
Docker Swam
Practical procedure step by step:-
1. Create amazon linux system
2. Install Docker
3. Enable password less authentication through SSH
Commands :
ssh-keygen
cat /root/.ssh/id_rsa.pub>>/root/.ssh/authorized_keys
chmod 755 /root/.ssh/authorized_keys
4. Now Server Ready.
Instead of doing same steps in slave systems, We created AMI (image)
5. With the help of Image , create new Ec2 instances
How many slaves you want, create that many Ec2 Instances.
6. Initialize Docker Swarm with below command
docker swarm init --advertise-addr MANAGER_IP
docker node ls
(this command will work only in swarm manager and not in worker)
SSH into worker node (machine) and run command to join swarm as worker
In Manager Run command - docker node ls to verify worker is registered and is ready
docker info
docker swarm
docker service ls
On manager node
If any Doubts/errors,
Please drop a error screenshots to [email protected]