-
Notifications
You must be signed in to change notification settings - Fork 810
Description
Is your feature request related to a problem? Please describe.
If one attempts to deploy a role assignment that already exists, the deployment will fail instead of gracefully acknowledging that the resource already exists and skipping it. If there were an "exists" method as covered in this issue, I would still have a hard time applying it to role assignments.
A role assignment has the following properties:
- RoleAssignmentId
- Scope
- DisplayName
- SignInName
- RoleDefinitionName
- RoleDefinitionId
- ObjectId
- ObjectType
- CanDelegate
- Description
- ConditionVersion
- Condition
Unfortunately, none of those are the name property that must be used to describe an existing resource in Bicep.
Describe the solution you'd like
I'd like to have some way to describe such an assignment nonetheless using any of the other properties, as in the following:
resource assignment 'Microsoft.Authorization/roleAssignments@<version>' existing = {
DisplayName: 'MyName'
RoleDefinitionName: 'MyRoleName'
}
Of course, this is no use until there is an exists method available, but following that, it would be an ideal to have it on the roadmap afterwards.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status