This PR adds functionality to graffiti monkey to allow for new tags to be added to instances based on existing ones. For example, if our instances were named dev-01 and dev-02, we could add a rule to add an owner=devmgr@mycompany.com and team=dev tag for any name starting with dev. This is achieved by regular expression rules. For example:
_instance_tags_to_add:
- key: Name
matches:
- match: ^dev.*
description: Development
tags_to_set_if_match:
owner: devmgr@mycompany.com
team: dev
Existing functionality is not impacted by this addition. The instance tagging is not triggered unless _instance_tags_to_add: is included in the configuration. This tagging can be disabled with --noinstances (as per the same convention used for volumes and snapshots) and it supports dry run with --dryrun
This PR adds functionality to graffiti monkey to allow for new tags to be added to instances based on existing ones. For example, if our instances were named dev-01 and dev-02, we could add a rule to add an
owner=devmgr@mycompany.com
andteam=dev
tag for any name starting withdev
. This is achieved by regular expression rules. For example:Existing functionality is not impacted by this addition. The instance tagging is not triggered unless
_instance_tags_to_add:
is included in the configuration. This tagging can be disabled with--noinstances
(as per the same convention used for volumes and snapshots) and it supports dry run with--dryrun