That task would still run on only the first host, and not the second.
Run_once will only perform the task on the first host... 

On Thursday, December 15, 2016 at 3:58:47 PM UTC+1, Brian Coca wrote:
>
> Then just fail the 'true' host and now you can use run once with 
> confidence only 'false' hosts got there.
>
> - script: myscript
>   register: myreturn
>   failed_when: not myreturn.stdout|bool
>
> - command: othertask
>   run_once: true
>
>
> ----------
> Brian Coca
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/cb574a23-b2b0-4955-8157-5a49765d2583%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to