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

fix(Instance/Volume): size_in_db should not be set when importing volume #837

Merged
merged 2 commits into from
May 20, 2021

Conversation

jeansebastienh
Copy link
Contributor

@jeansebastienh jeansebastienh commented May 17, 2021

When creating a volume from a snapshot or with a copy: the attribute "size_in_db" should not be read as it's conflicting with this feature

The test was failing:

resource_instance_volume_test.go:89: Step 1/1 error: After applying this test step, the plan was not empty.                                                                                                                               
        stdout:                                                                                                        
                                                                                                                                                                                                                                              
                                                                                                                                                                                                                                              
        An execution plan has been generated and is shown below.
        Resource actions are indicated with the following symbols:
          ~ update in-place
                                                         
        Terraform will perform the following actions:    
                                                          
        # scaleway_instance_volume.test2 will be updated in-place
          ~ resource "scaleway_instance_volume" "test2" {
                id              = "fr-par-1/ac5b205e-a19f-48a5-a7a0-2161b3736cf3"                                      
                name            = "tf-vol-wizardly-kilby"
              - size_in_gb      = 20 -> null                                                                           
                # (5 unchanged attributes hidden)
            }                              
                                                  
        Plan: 0 to add, 1 to change, 0 to destroy.

Now

--- PASS: TestAccScalewayInstanceVolume_FromVolume (1.91s)                                                             
PASS                                                                                                                   
ok      github.com/scaleway/terraform-provider-scaleway/scaleway        1.922s    

@remyleone remyleone merged commit 9a7ffbe into scaleway:master May 20, 2021
@jeansebastienh jeansebastienh deleted the fix-from-volume branch May 21, 2021 08:40
@remyleone remyleone added the instance Instance issues, bugs and feature requests label Jul 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
instance Instance issues, bugs and feature requests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants