pillar | category | online version |
---|---|---|
Cost Optimization |
Metadata tagging |
Tag resources with mandatory tags.
Metadata tags store additional information about resources. Each tags is a key value pair, with a tag name and tag value. When used consistently, metadata tags can be used to identify resources for searching and reporting. Up to 50 tags can be set on most resource types (see Tag support for Azure resources).
Additionally tags can store information useful to automated tasks. Some examples include; de-provisioning, scaling, and patching.
Consider tagging resources with the mandatory tags. Additionally consider enforcing mandatory tags and using inheritance with Azure Policy.
Resources pass when they have the required tags. If any of the tags are missing, this rule fails. Resources that do not support tags are skipped. By default:
- No mandatory tags are configured.
- Tag names are case-sensitive.
- Tag values are case-sensitive.
To configure this rule:
- Override the
CAF_ResourceMandatoryTags
configuration value with an array of required tags. - Override
CAF_MatchTagNameCase
withfalse
to make tag names case-insensitive. By default tag names are case-sensitive. This option affects all tag rules. - Override
CAF_MatchTagValueCase
withfalse
to make tag values case-insensitive. By default tag values are case-sensitive. This option affects all tag rules.