mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-05-02 23:31:25 -07:00
Add keyed_groups feature (#52045)
This implements: - Allow creating keyed group parents
This commit is contained in:
parent
646a8586a5
commit
56e3597856
4 changed files with 132 additions and 10 deletions
|
@ -53,9 +53,19 @@ EXAMPLES = r'''
|
|||
- prefix: distro
|
||||
key: ansible_distribution
|
||||
|
||||
# the following examples assume the first inventory is from contrib/inventory/ec2.py
|
||||
# this creates a group per ec2 architecture and assign hosts to the matching ones (arch_x86_64, arch_sparc, etc)
|
||||
- prefix: arch
|
||||
key: ec2_architecture
|
||||
|
||||
# this creates a group per ec2 region like "us_west_1"
|
||||
- prefix: ""
|
||||
separator: ""
|
||||
key: ec2_region
|
||||
|
||||
# this creates a common parent group for all ec2 availability zones
|
||||
- key: ec2_placement
|
||||
parent_group: all_ec2_zones
|
||||
'''
|
||||
|
||||
import os
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue