Azure / Azure/azure-rest-api-specs

[BUG] Microsoft.AzureStackHCI/clusters does not support user assigned identity as specified

Open
#28,260 2 comments 0 reactions 1 assignee Assigned to @priyjain358 View on GitHub
bug Mgmt
Dominant language
TypeSpec
Stars
3.1k
Forks
5.9k
Avg merge
2d 22h
Merged PRs (30d)
444

Description

### API Spec link

https://github.com/Azure/azure-rest-api-specs/blob/475747ff6322e9bf180b8911d871561b264379c3/specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2024-01-01/clusters.json#L163

### API Spec version

2023-08-01, 2024-01-01

### Describe the bug

According to swagger, `UserAssigned` should be supported for identity, but accually API does not.

https://github.com/Azure/azure-rest-api-specs/blob/475747ff6322e9bf180b8911d871561b264379c3/specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2024-01-01/clusters.json#L492

https://github.com/Azure/azure-rest-api-specs/blob/475747ff6322e9bf180b8911d871561b264379c3/specification/common-types/resource-management/v4/managedidentity.json#L35-L75

### Expected behavior

The API should support `UserAssigned` for identity.

### Actual behavior

The API does not support `UserAssigned` for identity.

### Reproduction Steps

PUT https://management.azure.com/subscriptions/xxx/resourceGroups/wt-hcitest/providers/Microsoft.AzureStackHCI/clusters/cluster?api-version=2024-01-01

```json
{
"type": "microsoft.azurestackhci/clusters",
"location": "eastus",
"identity": {
"type": "UserAssigned",
"userAssignedIdentities":{
"/subscriptions/xxx/resourceGroups/wt-hcitest/providers/Microsoft.ManagedIdentity/userAssignedIdentities/wt-uai":{}
}
},
"properties": {
}
}
```

400 Bad Request
x-ms-request-id df3d1ef8-177b-431f-a8c2-08951bc36c3e
x-ms-correlation-request-id df3d1ef8-177b-431f-a8c2-08951bc36c3e
```json
{
"error": {
"code": "CannotSetResourceIdentity",
"message": "Resource type 'Microsoft.AzureStackHCI/clusters' does not support creation of 'UserAssigned' resource identity. The supported types are 'SystemAssigned'."
}
}
```

### Environment

postman

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.