How to run two tasks at the same time

36 views
Skip to first unread message

Prathap Dasari

unread,
Nov 24, 2020, 12:18:12 PM11/24/20
to ansible...@googlegroups.com
Hi ,

How to run two tasks at the same time ? Kindly let me know if anyone knows about it.

Regards,
Prathap

Brian Coca

unread,
Dec 15, 2020, 11:48:41 AM12/15/20
to Ansible Project
By default ansible executs tasks in parallel across the targeted hosts
(limited by --forks). But I'm guessing you want on the same target,
there is no way to spawn 2 tasks in parallel at the same time, but
'async' will get you close (it will start executing the 'next task'
w/o waiting for the current to finish).

https://docs.ansible.com/ansible/latest/user_guide/playbooks_async.html




--
----------
Brian Coca

Reply all
Reply to author
Forward
0 new messages