1

I'm creating an Azure Resource Template and I'd like to assign the same set of tags to all my resources. I can create a variable to hold all my tag values like this:

"variables": {
  "mytags": {
    "project": "XyzProject",
    "department": "AbcDept",
    "owner": "Tom"
  }
}

And I can assign all the tags values individually like

"tags": {
  "project": "[variables('mytags').project]"
  "department": "[variables('mytags').department]"
  "owner": "[variables('mytags').owner]"
}

but (a) I have to repeat this for every resource and (b) if I add a new name-value pair to the tags I have to modify the tags element in every resource.

Is it possible to assign the whole of "mytags" at once?

Something like

"tags": variables('mytags')

juvchan
  • 6,113
  • 2
  • 22
  • 35
TomStones
  • 21
  • 2

1 Answers1

1

This isn't possible in AzureRM right now, but it should be... we'll get a bug filed on it.

bmoore-msft
  • 8,376
  • 20
  • 22