You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment Terraform Version
Terraform v0.11.10
A VM is created with both a Managed Service Identity, and an attached disk
Actual Behavior
terraform apply
azurerm_virtual_machine_data_disk_attachment.volumetest: Creating...
caching: "" => "ReadWrite"
create_option: "" => "Attach"
lun: "" => "10"
managed_disk_id: "" => "/subscriptions/2678e156-815b-4ed8-a214-18a708c038fd/resourceGroups/volumetest/providers/Microsoft.Compute/disks/volumetest"
virtual_machine_id: "" => "/subscriptions/2678e156-815b-4ed8-a214-18a708c038fd/resourceGroups/volumetest/providers/Microsoft.Compute/virtualMachines/volumetest"
write_accelerator_enabled: "" => "false"
Error: Error applying plan:
1 error(s) occurred:
* azurerm_virtual_machine_data_disk_attachment.volumetest: 1 error(s) occurred:
* azurerm_virtual_machine_data_disk_attachment.volumetest: Error updating Virtual Machine "volumetest" (Resource Group "volumetest") with Disk "volumetest": compute.VirtualMachinesClient#CreateOrUpdate: Failure sending request: StatusCode=0 -- Original Error: autorest/azure: Service returned an error. Status=400 Code="InvalidIdentityValues" Message="Invalid value for the identities '/subscriptions/2678e156-815b-4ed8-a214-18a708c038fd/resourcegroups/volumetest/providers/Microsoft.ManagedIdentity/userAssignedIdentities/volume-test-id'. The 'UserAssignedIdentities' property keys should only be empty json objects or null."
Terraform does not automatically rollback in the face of errors.
Instead, your Terraform state file has been partially updated with
any resources that successfully completed. Please address the error
above and apply again to incrementally change your infrastructure.
Steps to Reproduce
See configuration example above, add a valid ssh pubkey in ./files/id_rsa.pub, then run terraform apply
Important Factoids
If I manually remove the Managed Service Identity from the VM, the volume attaches and detaches fine. Once the VM has a Managed Service Identity, terraform can neither attach nor detach a disk - it always has the error shown above.
The key error seems to be:
Error updating Virtual Machine "volumetest" (Resource Group "volumetest") with Disk "volumetest": compute.VirtualMachinesClient#CreateOrUpdate: Failure sending request: StatusCode=0 -- Original Error: autorest/azure: Service returned an error. Status=400 Code="InvalidIdentityValues" Message="Invalid value for the identities '/subscriptions/2678e156-815b-4ed8-a214-18a708c038fd/resourcegroups/volumetest/providers/Microsoft.ManagedIdentity/userAssignedIdentities/volume-test-id'. The 'UserAssignedIdentities' property keys should only be empty json objects or null."
The text was updated successfully, but these errors were encountered:
I'm just wondering if there is any indication of whether this might make it into a workstream some time soon? If not, then we may need to redesign around the limitation in Azure
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks!
ghost
locked and limited conversation to collaborators
Nov 9, 2019
Community Note
Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment
Terraform Version
Terraform v0.11.10
provider.azurerm v1.19.0
Affected Resource(s)
azurerm_virtual_machine_data_disk_attachment
Terraform Configuration Files
Expected Behavior
A VM is created with both a Managed Service Identity, and an attached disk
Actual Behavior
terraform apply
Steps to Reproduce
See configuration example above, add a valid ssh pubkey in ./files/id_rsa.pub, then run
terraform apply
Important Factoids
If I manually remove the Managed Service Identity from the VM, the volume attaches and detaches fine. Once the VM has a Managed Service Identity, terraform can neither attach nor detach a disk - it always has the error shown above.
The key error seems to be:
Error updating Virtual Machine "volumetest" (Resource Group "volumetest") with Disk "volumetest": compute.VirtualMachinesClient#CreateOrUpdate: Failure sending request: StatusCode=0 -- Original Error: autorest/azure: Service returned an error. Status=400 Code="InvalidIdentityValues" Message="Invalid value for the identities '/subscriptions/2678e156-815b-4ed8-a214-18a708c038fd/resourcegroups/volumetest/providers/Microsoft.ManagedIdentity/userAssignedIdentities/volume-test-id'. The 'UserAssignedIdentities' property keys should only be empty json objects or null."
The text was updated successfully, but these errors were encountered: