Controlling execution strategies in Ansible
Adjusting Ansible playbook execution strategies is a common task among Ansible users. Different changes may require a certain order of operations. The default strategy Ansible uses is called linear, and it works great a majority of the time, but what if you’re automating a task that needs to be done in a specific order or way?
Strategies can be used to define how a playbook should be executed. Some basic strategies that can be used to control parallelism are the following:
linear(default): The playbook runs in a linear execution, each task is run in order, and the next task is not started until all hosts are finished with the current taskdebug: It allows the user to run the playbook interactively for troubleshooting purposesfree: The playbook is executed linearly, but each host runs the tasks at its own pace and has no requirement for all hosts to finish a task before continuing to the next task
...