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

Add IPv6 support aws_lightsail_instance #27699

Conversation

brittandeyoung
Copy link
Collaborator

@brittandeyoung brittandeyoung commented Nov 8, 2022

Description

This pull request modifies the aws_lightsail_instance and aws_lightsail_instance_public_ports resources to add support for ipv6. As a part of this, the bug which caused public ports not to provide a new resource with a new instance has been resolved.

I also updated the aws_lightsail_instance and aws_lightsail_key_pair resources to use the shared waitOperation function.

Relations

Closes #20680
Closes: #17588

References

Output from Acceptance Testing

$ make testacc TESTARGS='-run=TestAccLightsailInstance' PKG=lightsail
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/lightsail/... -v -count 1 -parallel 20  -run=TestAccLightsailInstance -timeout 180m
=== RUN   TestAccLightsailInstancePublicPorts_basic
=== PAUSE TestAccLightsailInstancePublicPorts_basic
=== RUN   TestAccLightsailInstancePublicPorts_multiple
=== PAUSE TestAccLightsailInstancePublicPorts_multiple
=== RUN   TestAccLightsailInstancePublicPorts_cidrs
=== PAUSE TestAccLightsailInstancePublicPorts_cidrs
=== RUN   TestAccLightsailInstancePublicPorts_disappears
=== PAUSE TestAccLightsailInstancePublicPorts_disappears
=== RUN   TestAccLightsailInstancePublicPorts_disappears_Instance
=== PAUSE TestAccLightsailInstancePublicPorts_disappears_Instance
=== RUN   TestAccLightsailInstance_basic
=== PAUSE TestAccLightsailInstance_basic
=== RUN   TestAccLightsailInstance_name
=== PAUSE TestAccLightsailInstance_name
=== RUN   TestAccLightsailInstance_tags
=== PAUSE TestAccLightsailInstance_tags
=== RUN   TestAccLightsailInstance_IPAddressType
=== PAUSE TestAccLightsailInstance_IPAddressType
=== RUN   TestAccLightsailInstance_disappears
=== PAUSE TestAccLightsailInstance_disappears
=== CONT  TestAccLightsailInstancePublicPorts_basic
=== CONT  TestAccLightsailInstance_basic
=== CONT  TestAccLightsailInstancePublicPorts_disappears
=== CONT  TestAccLightsailInstancePublicPorts_cidrs
=== CONT  TestAccLightsailInstancePublicPorts_multiple
=== CONT  TestAccLightsailInstance_IPAddressType
=== CONT  TestAccLightsailInstance_disappears
=== CONT  TestAccLightsailInstance_tags
=== CONT  TestAccLightsailInstance_name
=== CONT  TestAccLightsailInstancePublicPorts_disappears_Instance
--- PASS: TestAccLightsailInstancePublicPorts_disappears_Instance (57.96s)
--- PASS: TestAccLightsailInstance_basic (58.95s)
--- PASS: TestAccLightsailInstance_disappears (59.10s)
--- PASS: TestAccLightsailInstancePublicPorts_cidrs (60.04s)
--- PASS: TestAccLightsailInstancePublicPorts_basic (60.41s)
--- PASS: TestAccLightsailInstancePublicPorts_disappears (62.24s)
--- PASS: TestAccLightsailInstancePublicPorts_multiple (65.00s)
--- PASS: TestAccLightsailInstance_tags (74.81s)
--- PASS: TestAccLightsailInstance_IPAddressType (83.85s)
--- PASS: TestAccLightsailInstance_name (108.68s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/lightsail  110.906s


make testacc TESTARGS='-run=TestAccLightsailKeyPair' PKG=lightsail
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/lightsail/... -v -count 1 -parallel 20  -run=TestAccLightsailKeyPair -timeout 180m
=== RUN   TestAccLightsailKeyPair_basic
=== PAUSE TestAccLightsailKeyPair_basic
=== RUN   TestAccLightsailKeyPair_publicKey
=== PAUSE TestAccLightsailKeyPair_publicKey
=== RUN   TestAccLightsailKeyPair_encrypted
=== PAUSE TestAccLightsailKeyPair_encrypted
=== RUN   TestAccLightsailKeyPair_namePrefix
=== PAUSE TestAccLightsailKeyPair_namePrefix
=== CONT  TestAccLightsailKeyPair_basic
=== CONT  TestAccLightsailKeyPair_encrypted
=== CONT  TestAccLightsailKeyPair_namePrefix
=== CONT  TestAccLightsailKeyPair_publicKey
--- PASS: TestAccLightsailKeyPair_basic (36.74s)
--- PASS: TestAccLightsailKeyPair_encrypted (36.84s)
--- PASS: TestAccLightsailKeyPair_publicKey (37.41s)
--- PASS: TestAccLightsailKeyPair_namePrefix (37.51s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/lightsail  39.518s
...

@github-actions
Copy link

github-actions bot commented Nov 8, 2022

Community Note

Voting for Prioritization

  • Please vote on this pull request by adding a 👍 reaction to the original post to help the community and maintainers prioritize this pull request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

For Submitters

  • Review the contribution guide relating to the type of change you are making to ensure all of the necessary steps have been taken.
  • For new resources and data sources, use skaff to generate scaffolding with comments detailing common expectations.
  • Whether or not the branch has been rebased will not impact prioritization, but doing so is always a welcome surprise.

@github-actions github-actions bot added needs-triage Waiting for first response or review from a maintainer. documentation Introduces or discusses updates to documentation. service/lightsail Issues and PRs that pertain to the lightsail service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. size/L Managed by automation to categorize the size of a PR. and removed documentation Introduces or discusses updates to documentation. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. service/lightsail Issues and PRs that pertain to the lightsail service. labels Nov 8, 2022
@github-actions github-actions bot added documentation Introduces or discusses updates to documentation. service/lightsail Issues and PRs that pertain to the lightsail service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. labels Nov 8, 2022
@ewbankkit ewbankkit removed the needs-triage Waiting for first response or review from a maintainer. label Nov 8, 2022
Copy link
Contributor

@ewbankkit ewbankkit left a comment

Choose a reason for hiding this comment

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

LGTM 🚀.

% make testacc TESTARGS='-run=TestAccLightsailInstance_' PKG=lightsail ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/lightsail/... -v -count 1 -parallel 2  -run=TestAccLightsailInstance_ -timeout 180m
=== RUN   TestAccLightsailInstance_basic
=== PAUSE TestAccLightsailInstance_basic
=== RUN   TestAccLightsailInstance_name
=== PAUSE TestAccLightsailInstance_name
=== RUN   TestAccLightsailInstance_tags
=== PAUSE TestAccLightsailInstance_tags
=== RUN   TestAccLightsailInstance_IPAddressType
=== PAUSE TestAccLightsailInstance_IPAddressType
=== RUN   TestAccLightsailInstance_disappears
=== PAUSE TestAccLightsailInstance_disappears
=== CONT  TestAccLightsailInstance_basic
=== CONT  TestAccLightsailInstance_IPAddressType
--- PASS: TestAccLightsailInstance_basic (58.68s)
=== CONT  TestAccLightsailInstance_tags
--- PASS: TestAccLightsailInstance_IPAddressType (89.10s)
=== CONT  TestAccLightsailInstance_disappears
--- PASS: TestAccLightsailInstance_tags (70.97s)
=== CONT  TestAccLightsailInstance_name
--- PASS: TestAccLightsailInstance_disappears (53.31s)
--- PASS: TestAccLightsailInstance_name (109.83s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/lightsail	246.692s
% make testacc TESTARGS='-run=TestAccLightsailKeyPair_' PKG=lightsail ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/lightsail/... -v -count 1 -parallel 2  -run=TestAccLightsailKeyPair_ -timeout 180m
=== RUN   TestAccLightsailKeyPair_basic
=== PAUSE TestAccLightsailKeyPair_basic
=== RUN   TestAccLightsailKeyPair_publicKey
=== PAUSE TestAccLightsailKeyPair_publicKey
=== RUN   TestAccLightsailKeyPair_encrypted
=== PAUSE TestAccLightsailKeyPair_encrypted
=== RUN   TestAccLightsailKeyPair_namePrefix
=== PAUSE TestAccLightsailKeyPair_namePrefix
=== CONT  TestAccLightsailKeyPair_basic
=== CONT  TestAccLightsailKeyPair_encrypted
--- PASS: TestAccLightsailKeyPair_basic (30.47s)
=== CONT  TestAccLightsailKeyPair_publicKey
--- PASS: TestAccLightsailKeyPair_encrypted (30.92s)
=== CONT  TestAccLightsailKeyPair_namePrefix
--- PASS: TestAccLightsailKeyPair_publicKey (28.17s)
--- PASS: TestAccLightsailKeyPair_namePrefix (29.01s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/lightsail	64.342s

@ewbankkit
Copy link
Contributor

@brittandeyoung Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit 5ac983b into hashicorp:main Nov 8, 2022
@github-actions github-actions bot added this to the v4.39.0 milestone Nov 8, 2022
@github-actions
Copy link

This functionality has been released in v4.39.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@github-actions
Copy link

I'm going to lock this pull request 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 related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 11, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Introduces or discusses updates to documentation. service/lightsail Issues and PRs that pertain to the lightsail service. size/L Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
2 participants