Get the App
SLTechnology News&Howtos  ›  Servers  › 

What is the method of rapid expansion of Docker

Shulou Source: shulou.com Published: 2022-05-31 20:08:04 10月03日 Update

This article mainly explains "what is the method of rapid expansion of Docker". The content of the explanation is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "what is the method of rapid expansion of Docker".

1. Command mode

Run the nginx service in the created Swarm cluster and use the-- replicas parameter to specify the number of replicas to start.

Docker service create-- replicas 3-p 80:80-- name nginx nginx:latest

Or

Docker service create-p 80:80-- name nginx nginx:latestdocker service scale nginx=3docker service ls # check the copy 2. Portainer mode

You can use portainer to create a service on the web interface and specify the number of copies, and you can dynamically increase or decrease the number of copies at any time.

Thank you for your reading, the above is the content of "what is the method of rapid expansion of Docker". After the study of this article, I believe you have a deeper understanding of what is the method of rapid expansion of Docker, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Tags: Method copy way learning content situation service dynamic parameter at the same time command that is ideas articles more interface knowledge knowledge points articles follow Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno NVidia Shulou Tech Info MariaDB Microsoft Apple