diff --git a/infra/main.bicep b/infra/main.bicep index 44f3d2ea..fddd01bc 100644 --- a/infra/main.bicep +++ b/infra/main.bicep @@ -570,18 +570,22 @@ param createdBy string = contains(deployer(), 'userPrincipalName') ? split(deployer().userPrincipalName, '@')[0] : deployer().objectId +var existingTags = resourceGroup().tags ?? {} + // ========== Resource Group Tag ========== // resource resourceGroupTags 'Microsoft.Resources/tags@2025-04-01' = { name: 'default' properties: { - tags: { - ...resourceGroup().tags - ...tags + tags: union( + existingTags, + tags, + { TemplateName: 'Content Processing' Type: enablePrivateNetworking ? 'WAF' : 'Non-WAF' CreatedBy: createdBy DeploymentName: deployment().name } + ) } }