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

rd/aws_imagebuilder_image - add support for container_recipe_arn #23647

Conversation

kamilturek
Copy link
Collaborator

@kamilturek kamilturek commented Mar 12, 2022

Community Note

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

Closes #23380.

Output from acceptance testing:

$ make testacc TESTS="TestAccImageBuilderImage_containerRecipeARN" PKG=imagebuilder
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/imagebuilder/... -v -count 1 -parallel 20 -run='TestAccImageBuilderImage_containerRecipeARN'  -timeout 180m
=== RUN   TestAccImageBuilderImage_containerRecipeARN
=== PAUSE TestAccImageBuilderImage_containerRecipeARN
=== CONT  TestAccImageBuilderImage_containerRecipeARN
--- PASS: TestAccImageBuilderImage_containerRecipeARN (666.47s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/imagebuilder       668.203s
make testacc TESTS="TestAccImageBuilderImageDataSource_ARN_containerRecipeARN" PKG=imagebuilder
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/imagebuilder/... -v -count 1 -parallel 20 -run='TestAccImageBuilderImageDataSource_ARN_containerRecipeARN'  -timeout 180m
=== RUN   TestAccImageBuilderImageDataSource_ARN_containerRecipeARN
=== PAUSE TestAccImageBuilderImageDataSource_ARN_containerRecipeARN
=== CONT  TestAccImageBuilderImageDataSource_ARN_containerRecipeARN
--- PASS: TestAccImageBuilderImageDataSource_ARN_containerRecipeARN (549.80s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/imagebuilder       551.440s

@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/imagebuilder Issues and PRs that pertain to the imagebuilder 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/imagebuilder Issues and PRs that pertain to the imagebuilder service. labels Mar 12, 2022
@kamilturek kamilturek force-pushed the f-aws-imagebuilder-image-container-recipe-arn branch from 4740d14 to 3486224 Compare March 12, 2022 09:15
@github-actions github-actions bot added documentation Introduces or discusses updates to documentation. service/imagebuilder Issues and PRs that pertain to the imagebuilder service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. labels Mar 12, 2022
@@ -498,3 +521,130 @@ resource "aws_imagebuilder_image" "test" {
}
`, tagKey1, tagValue1, tagKey2, tagValue2))
}

func testAccImageContainerRecipeARNConfig(rName string) string {
return fmt.Sprintf(`
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I did not reuse the testAccImageBaseConfig as the base needed for container builds differs too much.

@kamilturek kamilturek force-pushed the f-aws-imagebuilder-image-container-recipe-arn branch from 3486224 to 1a06693 Compare March 15, 2022 22:40
@github-actions github-actions bot added size/XL Managed by automation to categorize the size of a PR. and removed size/L Managed by automation to categorize the size of a PR. labels Mar 15, 2022
@kamilturek kamilturek marked this pull request as ready for review March 16, 2022 08:54
@ewbankkit ewbankkit removed the needs-triage Waiting for first response or review from a maintainer. label Mar 16, 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=TestAccImageBuilderImageDataSource_\|TestAccImageBuilderImage_' PKG=imagebuilder ACCTEST_PARALLELISM=3
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/imagebuilder/... -v -count 1 -parallel 3  -run=TestAccImageBuilderImageDataSource_\|TestAccImageBuilderImage_ -timeout 180m
=== RUN   TestAccImageBuilderImageDataSource_ARN_aws
=== PAUSE TestAccImageBuilderImageDataSource_ARN_aws
=== RUN   TestAccImageBuilderImageDataSource_ARN_self
=== PAUSE TestAccImageBuilderImageDataSource_ARN_self
=== RUN   TestAccImageBuilderImageDataSource_ARN_containerRecipeARN
=== PAUSE TestAccImageBuilderImageDataSource_ARN_containerRecipeARN
=== RUN   TestAccImageBuilderImage_basic
=== PAUSE TestAccImageBuilderImage_basic
=== RUN   TestAccImageBuilderImage_disappears
=== PAUSE TestAccImageBuilderImage_disappears
=== RUN   TestAccImageBuilderImage_distributionARN
=== PAUSE TestAccImageBuilderImage_distributionARN
=== RUN   TestAccImageBuilderImage_enhancedImageMetadataEnabled
=== PAUSE TestAccImageBuilderImage_enhancedImageMetadataEnabled
=== RUN   TestAccImageBuilderImage_ImageTests_imageTestsEnabled
=== PAUSE TestAccImageBuilderImage_ImageTests_imageTestsEnabled
=== RUN   TestAccImageBuilderImage_ImageTests_timeoutMinutes
=== PAUSE TestAccImageBuilderImage_ImageTests_timeoutMinutes
=== RUN   TestAccImageBuilderImage_tags
=== PAUSE TestAccImageBuilderImage_tags
=== RUN   TestAccImageBuilderImage_containerRecipeARN
=== PAUSE TestAccImageBuilderImage_containerRecipeARN
=== CONT  TestAccImageBuilderImageDataSource_ARN_aws
=== CONT  TestAccImageBuilderImage_containerRecipeARN
=== CONT  TestAccImageBuilderImage_distributionARN
--- PASS: TestAccImageBuilderImageDataSource_ARN_aws (13.84s)
=== CONT  TestAccImageBuilderImageDataSource_ARN_containerRecipeARN
--- PASS: TestAccImageBuilderImage_containerRecipeARN (564.81s)
=== CONT  TestAccImageBuilderImageDataSource_ARN_self
--- PASS: TestAccImageBuilderImageDataSource_ARN_containerRecipeARN (661.21s)
=== CONT  TestAccImageBuilderImage_disappears
--- PASS: TestAccImageBuilderImage_distributionARN (1545.70s)
=== CONT  TestAccImageBuilderImage_ImageTests_timeoutMinutes
--- PASS: TestAccImageBuilderImageDataSource_ARN_self (1423.35s)
=== CONT  TestAccImageBuilderImage_tags
--- PASS: TestAccImageBuilderImage_disappears (1411.24s)
=== CONT  TestAccImageBuilderImage_basic
--- PASS: TestAccImageBuilderImage_ImageTests_timeoutMinutes (1409.18s)
=== CONT  TestAccImageBuilderImage_enhancedImageMetadataEnabled
--- PASS: TestAccImageBuilderImage_tags (1324.12s)
=== CONT  TestAccImageBuilderImage_ImageTests_imageTestsEnabled
--- PASS: TestAccImageBuilderImage_basic (1418.64s)
--- PASS: TestAccImageBuilderImage_enhancedImageMetadataEnabled (1165.68s)
--- PASS: TestAccImageBuilderImage_ImageTests_imageTestsEnabled (1042.40s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/imagebuilder	4357.913s

@ewbankkit
Copy link
Contributor

@kamilturek Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit 2656297 into hashicorp:main Mar 16, 2022
@github-actions github-actions bot added this to the v4.6.0 milestone Mar 16, 2022
@github-actions
Copy link

This functionality has been released in v4.6.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

github-actions bot commented May 7, 2022

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 May 7, 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/imagebuilder Issues and PRs that pertain to the imagebuilder service. size/XL 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
Development

Successfully merging this pull request may close these issues.

aws_imagebuilder_image container support
2 participants