如何在竹子中同时运行作业时避免停机

问题描述

Service has stopped in both the nodes,I just want everything else to be done simultaneously but there should not be any down time,Could someone please help me to solve this. Job is set up in Bamboo

解决方法

通过将其添加到您的剧本中,配置 ansible 以一一配置主机:

serial: 1

文档:https://docs.ansible.com/ansible/latest/user_guide/playbooks_strategies.html#setting-the-batch-size-with-serial

这假设您的 playbook 有在停止服务之后和继续到下一个主机之前启动服务的任务。