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
As per the datastore docs, setting the DRIVER attribute will override the DRIVER set in the image attributes and VM templates.
Setting the driver parameter for the disk attribute of a virtual_machine when the images comes from a datastore that overrides the driver results in the created disk being skipped over by matchDisk() and excluded from the saved terraform state. Thus the provider will repeatedly attach the same image over and over on subsequent runs of terraform apply.
The provider should save the disk it created in the terraform state, regardless of whether the driver matches what is expected.
Actual behavior
The disk is not saved to the terraform state, thus subsequent applies result in new attachments of the same disk.
Steps to Reproduce
Use the provided terraform configuration, run terraform apply with the datastore_id set to a datastore that overrides the DRIVER attribute using raw, and observe the confused state the provider get in.
Debug output
No response
Panic output
No response
Important factoids
No response
References
No response
The text was updated successfully, but these errors were encountered:
Description
As per the datastore docs, setting the
DRIVER
attribute will override theDRIVER
set in the image attributes and VM templates.Setting the
driver
parameter for thedisk
attribute of avirtual_machine
when the images comes from a datastore that overrides the driver results in the created disk being skipped over bymatchDisk()
and excluded from the saved terraform state. Thus the provider will repeatedly attach the same image over and over on subsequent runs ofterraform apply
.Terraform and Provider version
Terraform v1.4.6
on linux_amd64
Affected resources and data sources
The virtual_machine resource, likely also the template resource.
Terraform configuration
Expected behavior
The provider should save the disk it created in the terraform state, regardless of whether the
driver
matches what is expected.Actual behavior
The disk is not saved to the terraform state, thus subsequent applies result in new attachments of the same disk.
Steps to Reproduce
Use the provided terraform configuration, run
terraform apply
with thedatastore_id
set to a datastore that overrides theDRIVER
attribute usingraw
, and observe the confused state the provider get in.Debug output
No response
Panic output
No response
Important factoids
No response
References
No response
The text was updated successfully, but these errors were encountered: