@@ -106,17 +106,27 @@ module avmManagedIdentity './modules/managed-identity.bicep' = {
106106}
107107
108108// Assign Owner role to the managed identity in the resource group
109- module bicepOwnerRoleAssignment 'modules/role_assignment.bicep ' = {
110- name : format (deployment_param .resource_name_format_string , 'rbac -owner' )
109+ module avmRoleAssignment 'br/public:avm/ptn/authorization/resource-role-assignment:0.1.2 ' = {
110+ name : format (deployment_param .resource_name_format_string , 'role-assignment -owner' )
111111 params : {
112- managedIdentityResourceId : avmManagedIdentity .outputs .resourceId
113- managedIdentityPrincipalId : avmManagedIdentity .outputs .principalId
114- roleDefinitionId : subscriptionResourceId (
115- 'Microsoft.Authorization/roleDefinitions' ,
116- '8e3af657-a8ff-443c-a75c-2fe8c4bcb635'
117- ) // Built-in role 'Owner'
112+ resourceId : avmManagedIdentity .outputs .resourceId
113+ principalId : avmManagedIdentity .outputs .principalId
114+ roleDefinitionId : '8e3af657-a8ff-443c-a75c-2fe8c4bcb635'
118115 }
119116}
117+
118+ // Assign Owner role to the managed identity in the resource group
119+ // module bicepOwnerRoleAssignment 'modules/role_assignment.bicep' = {
120+ // name: format(deployment_param.resource_name_format_string, 'rbac-owner')
121+ // params: {
122+ // managedIdentityResourceId: avmManagedIdentity.outputs.resourceId
123+ // managedIdentityPrincipalId: avmManagedIdentity.outputs.principalId
124+ // roleDefinitionId: subscriptionResourceId(
125+ // 'Microsoft.Authorization/roleDefinitions',
126+ // '8e3af657-a8ff-443c-a75c-2fe8c4bcb635'
127+ // ) // Built-in role 'Owner'
128+ // }
129+ // }
120130// module managedIdentityModule 'deploy_managed_identity.bicep' = {
121131// name: 'deploy_managed_identity'
122132// params: {
0 commit comments