We normally just wrap it in a shell loop:

for i in inventories/*/hosts
  do
    ansible-playbook -i $i foo.yml
  done



On 13 February 2016 at 05:52, Nico K. <[email protected]> wrote:
> Hi,
>
> When one has multiple inventories like:
>
> inventories/a/hosts
> inventories/b/hosts
> inventories/..
>
> Is there an easy way to run a task or playbook against all of them without
> explicitly having to define each inventory on the command-line?
>
> The use case here is that all those groups contain machines for different
> departments or even sub-companies, however they all share certain
> SSL-certificates that I would like to be able to deploy to all hosts at
> once.
>
> Thanks,
> Nico.
>
> --
> 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 [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/7bfb3916-51cd-4963-94c4-1043d9cccdb6%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAK5eLPTrA63-4J%2BuW9AN_%2B-EuL5g8nQtVc3Nrujo3RQ3VKN0JQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to