Azure 360. Tags in Azure

Welcome Back. I hope you had a great week. Let’s pick up from where we left last time.

After planning carefully the naming convention and grouping assets using resource groups, there might be a need to further group assets for variety of reasons. Microsoft  provide us with the option to Tag resources. Tags are configured in a key / value pairs and can be used for:

·        Organising resources and creating additional views within the  Azure portal

·        Simplifying Azure billing

·        PowerShell / API access

Let’s look at few examples:

Key: Environment

Values: Prod, Dev, Test

Resource to be tagged: VM’s, NIC’s, Disks, Vnet’s, NSG’s, etc. –>  Can be used on any asset

Key: Cost Centre

Values: 100, 101, etc.

Resource to be tagged: VM’s, Disks, Storage Account –> If used for billing, require only on assets that attract charges

Key: AutoShutdownSchedule

Values: 7pm -> 6am

This is an example of addressing tags in a programmatic way. An automation account job runs periodically and compare the current time to the time specified in the Tag. The automation job can then perform an action based on the script (In the case above a job can turn on and off VM’s based on the time presented by the Tag).

Next week, I will point out some of the limitations of Azure and how to plan around it.