Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Create Ansible groups based on arbitrary host facts. #55571
This only affects the contributed foreman inventory script.
This allows the easy creation of Ansible groups from indicated foreman host facts.
This only affects the foreman.py contributed inventory script.
This change adds a couple of parameters to the foreman.ini file which configures the operation of the foreman.py inventory script. Specifically:
For example, given these settings in the foreman.ini file:
The group_facts parameter would create host groups (in our case, for example) of
The want_generated_parents would generate parent groups for all created "foreman_*" groups, which can be very handy. In our case for example without want_generated_parents we get these host groups:
but with want_generated_parents set to True, we also get these parent groups: