gpt4 book ai didi

docker - 如何从群中删除节点?

转载 作者:行者123 更新时间:2023-12-04 15:55:33 26 4
gpt4 key购买 nike

我使用静态文件模式向 swarm 集群添加了三个节点。我想从集群中删除 host1。但我没有找到 docker swarm remove命令:

Usage: swarm [OPTIONS] COMMAND [arg...]
Commands:
create, c Create a cluster
list, l List nodes in a cluster
manage, m Manage a docker cluster
join, j join a docker cluster
help, h Shows a list of commands or help for one command
如何从群中删除节点?

最佳答案

使用 Docker 版本:1.12.0,docker help优惠:

➜  docker help swarm

Usage: docker swarm COMMAND

Manage Docker Swarm

Options:
--help Print usage

Commands:
init Initialize a swarm
join Join a swarm as a node and/or manager
join-token Manage join tokens
update Update the swarm
leave Leave a swarm

Run 'docker swarm COMMAND --help' for more information on a command.

所以,接下来尝试:
➜  docker swarm leave --help

Usage: docker swarm leave [OPTIONS]

Leave a swarm

Options:
--force Force leave ignoring warnings.
--help Print usage

关于docker - 如何从群中删除节点?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34897268/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com