diff --git a/deployifnotexists-policy-with-initiative-and-assignment/main.json b/deployifnotexists-policy-with-initiative-and-assignment/main.json index ed20023..6f3f49c 100644 --- a/deployifnotexists-policy-with-initiative-and-assignment/main.json +++ b/deployifnotexists-policy-with-initiative-and-assignment/main.json @@ -437,7 +437,7 @@ "location": "global", "properties": { "description": "[parameters('metricAlertDescription')]", - "severity": "[parameters('metricAlertResourceNamespace')]", + "severity": "[parameters('metricAlertSeverity')]", "enabled": "[parameters('metricAlertEnabled')]", "scopes": [ "[[parameters('resourceId')]" @@ -623,6 +623,18 @@ } ] } + }, + { + "type": "Microsoft.Authorization/roleAssignments", + "apiVersion": "2020-04-01-preview", + "name": "[guid('bicepExampleAssignment', 'Microsoft.Authorization/policyAssignments', subscription().subscriptionId)]", + "properties": { + "principalId": "[reference(subscriptionResourceId('Microsoft.Authorization/policyAssignments', 'bicepExampleAssignment'), '2020-09-01', 'full').identity.principalId]", + "roleDefinitionId": "/providers/microsoft.authorization/roleDefinitions/b24988ac-6180-42a0-ab88-20f7382dd24c" + }, + "dependsOn": [ + "[subscriptionResourceId('Microsoft.Authorization/policyAssignments', 'bicepExampleAssignment')]" + ] } ] } @@ -636,7 +648,7 @@ "_generator": { "name": "bicep", "version": "0.3.1.62928", - "templateHash": "14501545516933283152" + "templateHash": "12435763967781024112" } } } \ No newline at end of file