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

imagebuilder/image_recipe: Add systems_manager_agent.uninstall_after_build argument #23293

Merged

Conversation

mattburgess
Copy link
Collaborator

@mattburgess mattburgess commented Feb 19, 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 #22159

Output from acceptance testing:

$ make testacc TESTS=TestAccImageBuilderImageRecipe PKG=imagebuilder
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/imagebuilder/... -v -count 1 -parallel 20 -run='TestAccImageBuilderImageRecipe'  -timeout 180m
=== RUN   TestAccImageBuilderImageRecipeDataSource_arn
=== PAUSE TestAccImageBuilderImageRecipeDataSource_arn
=== RUN   TestAccImageBuilderImageRecipe_basic
=== PAUSE TestAccImageBuilderImageRecipe_basic
=== RUN   TestAccImageBuilderImageRecipe_disappears
=== PAUSE TestAccImageBuilderImageRecipe_disappears
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName
=== RUN   TestAccImageBuilderImageRecipe_component
=== PAUSE TestAccImageBuilderImageRecipe_component
=== RUN   TestAccImageBuilderImageRecipe_componentParameter
=== PAUSE TestAccImageBuilderImageRecipe_componentParameter
=== RUN   TestAccImageBuilderImageRecipe_description
=== PAUSE TestAccImageBuilderImageRecipe_description
=== RUN   TestAccImageBuilderImageRecipe_tags
=== PAUSE TestAccImageBuilderImageRecipe_tags
=== RUN   TestAccImageBuilderImageRecipe_workingDirectory
=== PAUSE TestAccImageBuilderImageRecipe_workingDirectory
=== RUN   TestAccImageBuilderImageRecipe_pipelineUpdateDependency
=== PAUSE TestAccImageBuilderImageRecipe_pipelineUpdateDependency
=== RUN   TestAccImageBuilderImageRecipe_systemsManagerAgent
=== PAUSE TestAccImageBuilderImageRecipe_systemsManagerAgent
=== RUN   TestAccImageBuilderImageRecipe_userDataBase64
=== PAUSE TestAccImageBuilderImageRecipe_userDataBase64
=== RUN   TestAccImageBuilderImageRecipesDataSource_owner
    image_recipes_data_source_test.go:21: Step 1/1 error: Check failed: Check 3/6 error: data.aws_imagebuilder_image_recipes.self: Attribute 'arns.#' expected "1", got "2"
--- FAIL: TestAccImageBuilderImageRecipesDataSource_owner (22.29s)
=== RUN   TestAccImageBuilderImageRecipesDataSource_filter
=== PAUSE TestAccImageBuilderImageRecipesDataSource_filter
=== CONT  TestAccImageBuilderImageRecipeDataSource_arn
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID
=== CONT  TestAccImageBuilderImageRecipe_workingDirectory
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2
=== CONT  TestAccImageBuilderImageRecipesDataSource_filter
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted
=== CONT  TestAccImageBuilderImageRecipe_systemsManagerAgent
=== CONT  TestAccImageBuilderImageRecipe_pipelineUpdateDependency
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName
=== CONT  TestAccImageBuilderImageRecipe_userDataBase64
=== CONT  TestAccImageBuilderImageRecipe_component
=== CONT  TestAccImageBuilderImageRecipe_description
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName
=== CONT  TestAccImageBuilderImageRecipe_componentParameter
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3 (67.90s)
=== CONT  TestAccImageBuilderImageRecipe_tags
--- PASS: TestAccImageBuilderImageRecipe_componentParameter (71.16s)
=== CONT  TestAccImageBuilderImageRecipe_disappears
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted (71.72s)
=== CONT  TestAccImageBuilderImageRecipe_basic
--- PASS: TestAccImageBuilderImageRecipe_description (71.83s)
--- PASS: TestAccImageBuilderImageRecipesDataSource_filter (73.75s)
--- PASS: TestAccImageBuilderImageRecipeDataSource_arn (74.01s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize (75.52s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName (76.48s)
--- PASS: TestAccImageBuilderImageRecipe_workingDirectory (78.92s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID (80.54s)
--- PASS: TestAccImageBuilderImageRecipe_systemsManagerAgent (80.94s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice (81.77s)
--- PASS: TestAccImageBuilderImageRecipe_userDataBase64 (83.22s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName (83.32s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination (83.40s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops (84.63s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2 (84.72s)
--- PASS: TestAccImageBuilderImageRecipe_component (85.67s)
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID (90.54s)
--- PASS: TestAccImageBuilderImageRecipe_disappears (36.44s)
--- PASS: TestAccImageBuilderImageRecipe_pipelineUpdateDependency (109.48s)
--- PASS: TestAccImageBuilderImageRecipe_basic (41.86s)
--- PASS: TestAccImageBuilderImageRecipe_tags (86.03s)
FAIL
FAIL	github.com/hashicorp/terraform-provider-aws/internal/service/imagebuilder	176.273s
FAIL
make: *** [GNUmakefile:36: testacc] Error 1

Note that the failure in the datasource fails on current main branch too

@github-actions github-actions bot added size/M Managed by automation to categorize the size of a PR. service/imagebuilder Issues and PRs that pertain to the imagebuilder service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. needs-triage Waiting for first response or review from a maintainer. documentation Introduces or discusses updates to documentation. labels Feb 19, 2022
@mattburgess mattburgess force-pushed the imagebuilder-systemsmanageragent branch from ececb61 to ebbe8a3 Compare February 19, 2022 11:55
@mattburgess mattburgess force-pushed the imagebuilder-systemsmanageragent branch from ebbe8a3 to 90918f0 Compare February 19, 2022 11:58
@ewbankkit ewbankkit changed the title imagebuilder/image_recipe: Add `systems_manager_agent.uninstall_after… imagebuilder/image_recipe: Add systems_manager_agent.uninstall_after_build argument Feb 21, 2022
@ewbankkit ewbankkit removed the needs-triage Waiting for first response or review from a maintainer. label Feb 21, 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 TESTS=TestAccImageBuilderImageRecipe_ 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='TestAccImageBuilderImageRecipe_'  -timeout 180m
=== RUN   TestAccImageBuilderImageRecipe_basic
=== PAUSE TestAccImageBuilderImageRecipe_basic
=== RUN   TestAccImageBuilderImageRecipe_disappears
=== PAUSE TestAccImageBuilderImageRecipe_disappears
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice
=== RUN   TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName
=== PAUSE TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName
=== RUN   TestAccImageBuilderImageRecipe_component
=== PAUSE TestAccImageBuilderImageRecipe_component
=== RUN   TestAccImageBuilderImageRecipe_componentParameter
=== PAUSE TestAccImageBuilderImageRecipe_componentParameter
=== RUN   TestAccImageBuilderImageRecipe_description
=== PAUSE TestAccImageBuilderImageRecipe_description
=== RUN   TestAccImageBuilderImageRecipe_tags
=== PAUSE TestAccImageBuilderImageRecipe_tags
=== RUN   TestAccImageBuilderImageRecipe_workingDirectory
=== PAUSE TestAccImageBuilderImageRecipe_workingDirectory
=== RUN   TestAccImageBuilderImageRecipe_pipelineUpdateDependency
=== PAUSE TestAccImageBuilderImageRecipe_pipelineUpdateDependency
=== RUN   TestAccImageBuilderImageRecipe_systemsManagerAgent
=== PAUSE TestAccImageBuilderImageRecipe_systemsManagerAgent
=== RUN   TestAccImageBuilderImageRecipe_userDataBase64
=== PAUSE TestAccImageBuilderImageRecipe_userDataBase64
=== CONT  TestAccImageBuilderImageRecipe_basic
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice
=== CONT  TestAccImageBuilderImageRecipe_tags
--- PASS: TestAccImageBuilderImageRecipe_basic (23.76s)
=== CONT  TestAccImageBuilderImageRecipe_systemsManagerAgent
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMapping_noDevice (23.88s)
=== CONT  TestAccImageBuilderImageRecipe_userDataBase64
--- PASS: TestAccImageBuilderImageRecipe_systemsManagerAgent (21.10s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID
--- PASS: TestAccImageBuilderImageRecipe_userDataBase64 (22.06s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3
--- PASS: TestAccImageBuilderImageRecipe_tags (50.39s)
=== CONT  TestAccImageBuilderImageRecipe_description
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_kmsKeyID (22.61s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP3 (23.15s)
=== CONT  TestAccImageBuilderImageRecipe_componentParameter
--- PASS: TestAccImageBuilderImageRecipe_description (23.56s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize
--- PASS: TestAccImageBuilderImageRecipe_componentParameter (20.34s)
=== CONT  TestAccImageBuilderImageRecipe_component
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeTypeGP2 (22.25s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_volumeSize (20.79s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMapping_virtualName (20.65s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination
--- PASS: TestAccImageBuilderImageRecipe_component (30.00s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_deleteOnTermination (23.30s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_snapshotID (50.01s)
=== CONT  TestAccImageBuilderImageRecipe_disappears
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMapping_deviceName (21.96s)
=== CONT  TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted
--- PASS: TestAccImageBuilderImageRecipe_disappears (18.24s)
=== CONT  TestAccImageBuilderImageRecipe_workingDirectory
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_iops (22.01s)
=== CONT  TestAccImageBuilderImageRecipe_pipelineUpdateDependency
--- PASS: TestAccImageBuilderImageRecipe_BlockDeviceMappingEBS_encrypted (20.51s)
--- PASS: TestAccImageBuilderImageRecipe_workingDirectory (22.35s)
--- PASS: TestAccImageBuilderImageRecipe_pipelineUpdateDependency (65.36s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/imagebuilder	229.670s

@ewbankkit
Copy link
Contributor

@mattburgess Thanks for the contribution 🎉 👏.

@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 May 14, 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/M 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.

imagebuilder: specify "systems_manager_agent/uninstall_after_build" parameter in aws_imagebuilder_image_recipe
2 participants