-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better DiffSuppressFunc for disk image field #884
Conversation
--- PASS: TestAccComputeDisk_timeout (0.09s)
--- PASS: TestAccComputeDisk_encryption (23.44s)
--- PASS: TestAccComputeDisk_basic (24.17s)
--- PASS: TestAccComputeDisk_update (45.20s)
--- PASS: TestAccComputeDisk_deleteDetach (62.05s)
--- PASS: TestAccComputeDisk_fromSnapshot (107.61s) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will work for that particular shorthand case, but it's not comprehensive. I'm fine with fixing it this way with the assumption that the majority of users are either specifying full URLs or this particular shorthand, but technically there are other cases that aren't handled (basically any of the "family" ones from https://github.com/terraform-providers/terraform-provider-google/blob/master/google/image.go)
I wasn't aware of the family case. I will update this PR to handle it. |
@danawillow I handle more cases now. Could you re-review it? Thanks |
Signed-off-by: Modular Magician <magic-modules@google.com>
when I try to resize disk it is still replacing the instance. My Terraform version is v0.12.9. terraform plan output:
|
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! |
Fixes #861
Resizing disk while the instance is running is already supported. The problem came from a diff in the image field causing a ForceNew.
This PR adds a better DiffSuppressFunc for the disk image field which allows to resize the disk without causing a force new.