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

provider/scaleway: Expose IPv6 support, improve documentation #7784

Merged
merged 9 commits into from
Jul 25, 2016
Merged

provider/scaleway: Expose IPv6 support, improve documentation #7784

merged 9 commits into from
Jul 25, 2016

Conversation

nicolai86
Copy link
Contributor

@nicolai86 nicolai86 commented Jul 23, 2016

This PR improves the Scaleway provider by

  • exposing IPv6 support for the scaleway_server resource
  • exposing security group support for the scaleway_server resource
  • unifying attribute names (ipv4_address_public -> public_ip, ipv4_address_private -> private_ip)
  • updating scaleway_server resource docs with more options

nicolai86 added a commit to nicolai86/scaleway-terraform-demo that referenced this pull request Jul 23, 2016
@stack72
Copy link
Contributor

stack72 commented Jul 25, 2016

Hi @nicolai86

Just a FYI, when I went to run the tests, I received a panic (as follows):

% make testacc TEST=./builtin/providers/scaleway TESTARGS='-run=TestAccScaleway'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
TF_ACC=1 go test ./builtin/providers/scaleway -v -run=TestAccScaleway -timeout 120m
=== RUN   TestAccScalewayIP_Basic
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x0 pc=0x8b9d5]

goroutine 61 [running]:
panic(0x74a700, 0xc82000e0f0)
    /opt/boxen/homebrew/Cellar/go/1.6.2/libexec/src/runtime/panic.go:481 +0x3e6
github.com/hashicorp/terraform/builtin/providers/scaleway.resourceScalewayIPRead(0xc820221440, 0x5e7d00, 0xc82008a5c0, 0x0, 0x0)
    /Users/stacko/Code/go/src/github.com/hashicorp/terraform/builtin/providers/scaleway/resource_scaleway_ip.go:57 +0x465
github.com/hashicorp/terraform/builtin/providers/scaleway.resourceScalewayIPUpdate(0xc820221440, 0x5e7d00, 0xc82008a5c0, 0x0, 0x0)
    /Users/stacko/Code/go/src/github.com/hashicorp/terraform/builtin/providers/scaleway/resource_scaleway_ip.go:75 +0x4ec
github.com/hashicorp/terraform/builtin/providers/scaleway.resourceScalewayIPCreate(0xc820221440, 0x5e7d00, 0xc82008a5c0, 0x0, 0x0)
    /Users/stacko/Code/go/src/github.com/hashicorp/terraform/builtin/providers/scaleway/resource_scaleway_ip.go:37 +0xc5
github.com/hashicorp/terraform/helper/schema.(*Resource).Apply(0xc820070ba0, 0xc8202440c0, 0xc8202296c0, 0x5e7d00, 0xc82008a5c0, 0x123a01, 0x0, 0x0)

@stack72 stack72 added the waiting-response An issue/pull request is waiting for a response from the community label Jul 25, 2016
@nicolai86
Copy link
Contributor Author

nicolai86 commented Jul 25, 2016

@stack72 thanks for finding this bug. I've fixed it with e065231

@nicolai86
Copy link
Contributor Author

Now all the tests pass again as well:

F_ACC=1 go test ./builtin/providers/scaleway -v -run=TestAccScaleway -timeout 120m
=== RUN   TestAccScalewayIP_Basic
--- PASS: TestAccScalewayIP_Basic (8.26s)
=== RUN   TestAccScalewaySecurityGroupRule_Basic
--- PASS: TestAccScalewaySecurityGroupRule_Basic (3.85s)
=== RUN   TestAccScalewaySecurityGroup_Basic
--- PASS: TestAccScalewaySecurityGroup_Basic (1.71s)
=== RUN   TestAccScalewayServer_Basic
--- PASS: TestAccScalewayServer_Basic (156.47s)
=== RUN   TestAccScalewayServer_SecurityGroup
--- PASS: TestAccScalewayServer_SecurityGroup (154.91s)
=== RUN   TestAccScalewayVolumeAttachment_Basic
--- PASS: TestAccScalewayVolumeAttachment_Basic (343.53s)
=== RUN   TestAccScalewayVolume_Basic
--- PASS: TestAccScalewayVolume_Basic (17.16s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/scaleway   685.903s

@stack72
Copy link
Contributor

stack72 commented Jul 25, 2016

Thanks for the fix @nicolai86 :)

The tests now look good! Thanks again for all the work here!

% make testacc TEST=./builtin/providers/scaleway TESTARGS='-run=TestAccScaleway'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
TF_ACC=1 go test ./builtin/providers/scaleway -v -run=TestAccScaleway -timeout 120m
=== RUN   TestAccScalewayIP_Basic
--- PASS: TestAccScalewayIP_Basic (10.50s)
=== RUN   TestAccScalewaySecurityGroupRule_Basic
--- PASS: TestAccScalewaySecurityGroupRule_Basic (2.65s)
=== RUN   TestAccScalewaySecurityGroup_Basic
--- PASS: TestAccScalewaySecurityGroup_Basic (1.73s)
=== RUN   TestAccScalewayServer_Basic
--- PASS: TestAccScalewayServer_Basic (128.98s)
=== RUN   TestAccScalewayServer_SecurityGroup
--- PASS: TestAccScalewayServer_SecurityGroup (128.87s)
=== RUN   TestAccScalewayVolumeAttachment_Basic
--- PASS: TestAccScalewayVolumeAttachment_Basic (315.44s)
=== RUN   TestAccScalewayVolume_Basic
--- PASS: TestAccScalewayVolume_Basic (2.68s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/scaleway   590.860s

@stack72 stack72 merged commit 9f314a3 into hashicorp:master Jul 25, 2016
@nicolai86 nicolai86 deleted the scaleway-update branch July 25, 2016 13:49
@sheerun
Copy link
Contributor

sheerun commented Sep 5, 2016

@nicolai86 For some reason when creating 2 security groups, just as described here: https://www.terraform.io/docs/providers/scaleway/index.html Two rules get created but both get 443 port instead of one getting 80 and the other 443.

@nicolai86
Copy link
Contributor Author

@sheerun I've seen the same problem too, when creating a security group with multiple rules. Would you mind creating a bug for this so we can track down the issue?

@ghost
Copy link

ghost commented Apr 22, 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 22, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement provider/scaleway waiting-response An issue/pull request is waiting for a response from the community
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants