I'm experimenting with the new AWS_EC2 plugin and have been wondering if
there's a way to streamline the file as we have separate inventory folders
for dev, demo and prod. Is there a way to do something like and 'include'
for the bulk of the YAML file content and just have the different
environment filters in each inventory's specific file? eg. something like
this:
Central file (central.aws_ec2.yml):
plugin: aws_ec2
regions:
- us-east-1
- us-east-1
- us-west-1
- us-west-2
- ap-southeast-2
filters:
instance-state-name: running
strict_permissions: False
hostnames:
- tag:Name
- private-ip-address
strict: False
keyed_groups:
- prefix: ''
separator: ''
key: tags.Type
Demo inventory file (demo.aws_ec2.yml):
include: central.aws_ec2.yml
filters:
tag:Environment: demo
Thanks,
Guy
--
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/3199f5c1-ce55-4a87-9492-af87246035d1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.