简体   繁体   English

启动docker守护程序时如何禁用/离开docker swarm模式?

[英]How to disable/leave docker swarm mode when starting docker daemon?

is there any way to disable/leave the swarm mode of docker when starting the daemon manually, eg dockerd --leave-swarm , instead of starting the daemon and leave the swarm mode afterwards, eg using docker swarm leave ? 有什么方法可以在手动启动守护程序时禁用/退出dockerd --leave-swarm swarm模式,例如dockerd --leave-swarm ,而不是启动守护程序并随后退出swarm模式,例如使用docker swarm leave吗?

Many thanks in advance, Aljoscha 在此先感谢,Aljoscha

I don't think this is anticipated by docker developers. 我认为这不是docker开发人员所期望的。 When node leaves swarm, it needs to notify swarm managers, that it will not be available anymore. 当节点离开群集时,它需要通知群集管理器,该群集将不再可用。

Leaving swarm is a one time action and passing this as an configuration option to the daemon is weird. 留下群体是一次性的动作,将其作为配置选项传递给守护程序是很奇怪的。 You may try to suggest that on docker's github, but I don't think it will have much supporters. 您可能会建议在docker的github上提出建议,但我认为它不会有太多支持者。

Perhaps more intuitive option would be to have ability to start dockerd in a way that communication to docker swarm manager would be suspended - so your dockerd is running only locally, but if you start without that flag (--local?) it would reconnect to swarm that it was attached before. 也许更直观的选择是能够以与docker swarm manager的通信被暂停的方式启动dockerd-因此您的dockerd仅在本地运行,但是如果您启动时没有该标志(--local?),它将重新连接到蜂拥而至。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM