Hi,

As explained 
here 
http://docs.ansible.com/intro_inventory.html#splitting-out-host-and-group-specific-data
 
we are using multiple environments (acceptance / production) with 
ansible-playbooks and have set it up as follow:

deploy.yml
inventory
|_ inventory-production
|_inventory-acceptance
group_vars/
|_ acceptance/group1
|_ acceptance/group2
|_ production/group1
|_ production/group2
host_vars/
|_ host1.accept
|_ host2.accept
|_ host1.prod
|_ host2.prod
...

We have for instance some iptables vars defined in group1 and group2. Each 
specific for their group of hosts.
Now when we run the ansible playbook deploy.yml together with the 
inventory-production inventory it soon start to work on a host in group1. 
It will run the tasks for the iptables role and the taks will need vars 
from the group_vars directory. However it seems it is using the vars that 
has been combined of both groups and it will use the vars which are 
alphabetical last. Which in this case is group2. So it is using the wrong 
vars.

Any idea why this is going wrong?

-- 
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/b25c4dd2-04dd-4779-848e-f1482ec77214%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to