Tags for Cloud Resources: Tips and Best Practices

Cloud service providers (such as AWS, Azure, and GCP), allow us to add tags to cloud resources. These tags serve multiple functions.

This post gives a brief overview of what tags are and why we should use them when managing environments in the cloud.

Tags are metadata that we can add to a cloud resource (such as virtual machine, network interface, volume disk, etc.) for logical organization of resources.

Tags are text-based strings. Therefore, it is recommended to create them consistently across all cloud resources.

Why should you tag cloud resources?

  • Cost allocation – Tagging enables us to differentiate between projects, departments, customers, etc. for billing reports
  • Automation – Tagging enables us to put all relevant resources (compute, network, storage, etc.) in one place for the use of automation tools/scripts. For example, to turn off all resources with the same tag every night.
  • Access control – Tagging enables us to control who has access to specific resources – for example who has privileges to see a dashboard of currently used resources in a specific project.

Cloud providers have been kind enough to create guidelines and tips for tagging. Here are just a few:

AWS:

  • How should I tag my AWS resources?

https://aws.amazon.com/answers/account-management/aws-tagging-strategies/

  • Tagging Your Amazon EC2 Resources

https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html

Azure:

  • Use tags to organize your Azure resources

https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-using-tags

  • Azure Resource Tagging Best Practices

http://www.azurefieldnotes.com/2016/07/18/azure-resource-tagging-best-practices/

GCP:

  • Best Practices for Enterprise Organizations

https://cloud.google.com/docs/enterprise/best-practices-for-enterprise-organizations

  • Using labels to organize Google Cloud Platform resources

https://cloudplatform.googleblog.com/2015/10/using-labels-to-organize-Google-Cloud-Platform-resources.html

Eyal Estrin
Eyal Estrin is a Cloud Architect.
He joined IUCC in December 2017 and his main focus is promoting and supporting cloud services in Universities in Israel. He brings with him more than 20 years of experience in the IT and information security field.
Follow him at @eyalestrin