Ansible is designed to work this way intentionally as it's quite useful for
inter-machine orchestration and extremely useful for fine grained control
when we want to do things like work with load balancers.

You might possibly want to consider invoking ansible-pull (or just ansible
in local mode) from ansible if you want that architecture.

It's not going to be possible to do this with a "stock" push-mode
ansible-playbook -- also think about how messy the output would be trying
to read it from the CLI!  :)

I should also mention that AWX has a nice callback feature that allows a
node to phone home and request configuration that you might be interested
in.   Basically you just request a special URL via curl, AWX verifies the
requesting system was in inventory, and then it will reach out and
configure that system in standard push mode, but it doesn't have to wait on
other systems.   (Note:  this is not the standard way AWX operates, but
it's a supported feature).

I would probably recommend invoking ansible-pull via an async task for most
basic use cases, though you're not going to have as nice of standard output.






On Mon, Jan 13, 2014 at 10:26 PM, Tao Fan <t...@taggle.com.au> wrote:

> Hi Mark,
>
> Thanks for the reply. I am aware of the async action but this is not what
> I am looking for. async kicks off task, but still blocks other tasks before
> all hosts have finished that particular task. Fire and forget is not an
> option for me either. What I am looking for is that when host 1 has
> finished task1, it will go on to task2 regardless host2 has finished task1
> or not.
>
> Thanks again.
>
> On Tuesday, 14 January 2014 04:35:02 UTC+11, Mark Phillips wrote:
>>
>> Hi,
>>
>> Take a look at asynchronous actions: http://docs.ansible.com/playbooks_
>> async.html
>>
>> On Monday, 13 January 2014 00:13:19 UTC, Tao Fan wrote:
>>>
>>> Hi all,
>>>
>>> I have search around for this but they are all about running one task
>>> concurrently for multiple hosts. What I am trying to get is running
>>> multiple tasks concurrently, meaning if one host, for whatever reason, even
>>> ssh timeout, has slow execution, it should not block the task execution go
>>> on to the next for other hosts. How can I achieve this within ansible? I
>>> can do a wrapper of the ansible-playbook command but wonder if ansible
>>> supports this natively.
>>>
>>>
>>> Thanks,
>>>
>>> Tao
>>>
>>  --
> You received this message because you are subscribed to the Google Groups
> "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to ansible-project+unsubscr...@googlegroups.com.
> To post to this group, send email to ansible-project@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>



-- 
Michael DeHaan <mich...@ansibleworks.com>
CTO, AnsibleWorks, Inc.
http://www.ansibleworks.com/

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to