Docker Swarm is a clustering and booking tool for Docker containers. With Swarm, IT specialists and engineers can set up and deal with a group of Docker nodes as a solitary virtual framework.
When a gathering of machines has been bunched together, you can even now run the Docker orders that you're used to, however, they will presently be done by the machines in your group.
The exercises of the cluster are constrained by a swarm chief, and machines that have joined the group are alluded to as nodes.
To know Docker Swarm in detail, please check out this link.
In this article, we will be learning some of the most useful
Docker Swarm Commands.
Docker Swarm Command
|
Purpose
|
docker swarm ca
|
To
Display and rotate the root CA
|
docker swarm init
|
To
Initialize a docker swarm
|
docker swarm join
|
To
join a swarm as a node and/or manager
|
docker swarm join-token
|
To
Manage join tokens
|
docker swarm leave
|
To
Leave the docker swarm
|
docker swarm unlock
|
To
unlock docker swarm
|
docker swarm unlock- key
|
To
Manage the unlock key
|
docker swarm update
|
To
update the docker swarm
|
docker service ls
|
To
List docker services
|
docker service create <name> <image-name>
|
To
Create a new service
|
docker service rm <name>
|
To
remove docker service
|
docker service scale <name>
|
To
scale docker services
|