Azure Role-based access control
An Azure service that provides fine-grained access management for Azure resources, enabling you to grant users only the rights they need to perform their jobs.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
HI..
Can we change azure role assignment for some account from owner to reader without deleting an re-adding the account?
You have to unassign the role from Owner and then add Reader, you cannot do a swap, if you add Reader on its own, it will still have Owner.
So you have to remove the rights that you don't want.
Role assignment can be changed without deleting and re-adding the account. Here is the way to "Update" the role assignment of a user over a subscription.
az role assignment list --subscription <sub id> {
"canDelegate": null,
"condition": null,
"conditionVersion": null,
"description": null,
"id": "/subscriptions/id/providers/Microsoft.Authorization/roleAssignments/66b5d81f-1f82-4562-bded-117787a0fc5a",
"name": "name",
"principalId": "id",
"principalName": "******@cloudcompute.info",
"principalType": "User",
"roleDefinitionId": "/subscriptions/id/providers/Microsoft.Authorization/roleDefinitions/8e3af657-a8ff-443c-a75c-2fe8c4bcb635",
"roleDefinitionName": "Owner",
"scope": "/subscriptions/id",
"type": "Microsoft.Authorization/roleAssignments"
}
"roleDefinitionId": "/subscriptions/id/providers/Microsoft.Authorization/roleDefinitions/8e3af657-a8ff-443c-a75c-2fe8c4bcb635",
"roleDefinitionName": "Owner",
az role assignment update --role-assignment assignment.json--please don't forget to upvote and Accept as answer if the reply is helpful--