Skip to content
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

Allow resizing of Google Cloud persistent disks #15077

Merged
merged 1 commit into from
Jun 5, 2017

Conversation

bashtoni
Copy link

@bashtoni bashtoni commented Jun 5, 2017

make testacc TEST=./builtin/providers/google TESTARGS='-run=TestAccComputeDisk_updateSize'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/06/05 11:31:09 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/google -v -run=TestAccComputeDisk_updateSize -timeout 120m
=== RUN   TestAccComputeDisk_updateSize
--- PASS: TestAccComputeDisk_updateSize (28.37s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/google	28.377s

Copy link
Contributor

@stack72 stack72 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @bashtoni

Left a few small things inline - please let me know your thoughts

Paul

@@ -68,7 +69,7 @@ func resourceComputeDisk() *schema.Resource {
"size": &schema.Schema{
Type: schema.TypeInt,
Optional: true,
ForceNew: true,
ForceNew: false,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be removed completely :)

return err
}

if d.HasChange("size") {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the machine have to be stopped? Do we have to wait for a specific status before we know that this has worked as expected?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resizing is an on-line operation. The API docs don't specify the possible states of a disk, and I've never been able to observe another state than 'Ready'.

@radeksimko radeksimko added the waiting-response An issue/pull request is waiting for a response from the community label Jun 5, 2017
@bashtoni bashtoni force-pushed the google-disk-resize branch from d893325 to 18fdcf2 Compare June 5, 2017 12:38
@bashtoni
Copy link
Author

bashtoni commented Jun 5, 2017

@stack72 Thanks for reviewing Paul. I removed the unnecessary ForceNew: false.

@radeksimko radeksimko removed the waiting-response An issue/pull request is waiting for a response from the community label Jun 5, 2017
@stack72
Copy link
Contributor

stack72 commented Jun 5, 2017

LGTM! thanks for making the change and the explanation :)

P.

@ghost
Copy link

ghost commented Apr 11, 2020

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants