New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
various issues with YAML hosts and multiple groups #395
Comments
If a host is in multiple groups, the groups list does not seem to contain all groups. It may be all in the groups still, just that the variable is not updated. Do not know if this also occurs in the JSON version, testing welcome. |
See the following ansible-hosts: [qa-db-hosts] [qa1-hosts] esiqagw98 has in setup"
it seems, that only its first group has been set. Cheers, R. |
Also, the template {% if 'qa-db-hosts' in groups %} expands for esiqagw98 to x.y.z.v some-other-internal-host so, it seems there is some other problem with {% if 'aaa' in groups %}, not only determining complete list of groups for host. |
Yes, this is a known issue with hosts in multiple groups with the INI format. If someone wants to look into fixing it, that will be great and allow us to get 0.4 out sooner. I'm not aware of any other major issues blocking things. On Wednesday, May 16, 2012 at 7:55 AM, rylach wrote:
|
Another related issue: when you add a host to INI file more then once, you have to define every time all its variables, e.g.: [groupA] [groupAB] if you use groupAB in playbook - you won't see 'varA'; you have to define it in group A or switch order of groups. Do you agree, that it should be also fixed? |
yes |
fixed on devel, let me know if this works for you or not, unit tests are updated and seems good to me. |
Was just working on this myself and came up with almost the same change. Looks good to me. |
Ansible: devel, r404c3acbbf5ed3f2f6a5a2f64cc230cd22317e15
OS: Ubuntu 12.04
Python: 2.7.3
When a host is listed both "globally" and within a group, e.g.
The 'setup' command lists it only as belonging to "ungrouped" and ignores any group vars:
The text was updated successfully, but these errors were encountered: