Open Philbow opened 1 month ago
@Philbow, by design, you cannot choose a different storage container when creating a VM from an existing image. You can check this by following the steps through the Prism Central interface.
To understand this better, is your intention to add an additional disk to the virtual machine, or to specify where to store the cloned image disk for that VM?
Sure I forgot that the image is only referenced in the VM to reduce storage usage - this makes sense.
A second disk without image reference would use the defined storage container.
An error for mutual exclusivness would be helpful. Please decide if this makes sense or not (and close the ticket if you wish so).
Thanks for the quick response.
Nutanix Cluster Information
Terraform Version
Affected Resource(s)
Terraform Configuration Files
Debug Output
After running terraform apply a second time, Terraform indicates changes to the storage container
nutanix_virtual_machine.vm will be updated in-place
~ resource "nutanix_virtual_machine" "vm" { id = "cec615e1-b5cf-4fb1-a23b-6fcd96bc86f6" name = "###ADD_YOUR_VALUE###"
(41 unchanged attributes hidden)
~ disk_list {
(5 unchanged attributes hidden)
}
Expected Behavior
When using a data_source_reference with image, Terraform should use the correctly specified storage container in the first run, to omit unsupported changes in the second run.
Actual Behavior
When using a data_source_reference with image, Terraform uses a wrong storage container (SelfServiceContainer) in the first run.
Steps to Reproduce
terraform apply -auto-approve
terraform apply
to see unplanned changes or check the storage container in the UI from the first runImportant Factors