ansible/ansible — pull request #4003 by herbyg-axial (2013-09-03 01:18:20+00:00)
Title: Make it possible to group instances based off the expansion of the comma-seperated values of specified instance tags

In AWS, instance tags are unique and you cannot have multiple tags with the same name.

But there are situations where you'd like multiple values for a particular tag name, and as such, you'd end up setting the value to be a comma-seperated string.

This change adds the ability to specify which tags will have their values expanded and used to assign new tag groups.

For example, if you had a tag set like this on an instance:
roles = "www, db, frontend"

...and you specified the tag name 'roles' in the 'expanded_tag_names' setting, then the ec2 inventory script would create 3 additional tag groups:

tag_roles_www
tag_roles_db
tag_roles_frontend