Describe the bug
Azure CLI does not allow to to remove identity from replica server.
Resource Provider API allows such operation and completes it successfully.
Related command
az mysql flexible-server identity remove
Errors
Cannot remove identities from a server with replication role. Use the primary server instead.
Issue script & Debug output
Create MySQL Flexible server replica with user assigned managed identity.
Try to remove identity using az mysql flexible-server identity remove.
Operation fails on the client side validation performed by Azure CLI.
|
if instance.replication_role == 'Replica': |
|
raise CLIError("Cannot assign identities to a server with replication role. Use the primary server instead.") |
Expected behavior
Identity to be removed successfully.
Environment Summary
azure-cli 2.64.0
core 2.64.0
telemetry 1.1.0
Additional context
No response
Describe the bug
Azure CLI does not allow to to remove identity from replica server.
Resource Provider API allows such operation and completes it successfully.
Related command
az mysql flexible-server identity removeErrors
Cannot remove identities from a server with replication role. Use the primary server instead.
Issue script & Debug output
Create MySQL Flexible server replica with user assigned managed identity.
Try to remove identity using
az mysql flexible-server identity remove.Operation fails on the client side validation performed by Azure CLI.
azure-cli/src/azure-cli/azure/cli/command_modules/mysql/custom.py
Lines 1625 to 1626 in d1369fd
Expected behavior
Identity to be removed successfully.
Environment Summary
azure-cli 2.64.0
core 2.64.0
telemetry 1.1.0
Additional context
No response