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

r/aws_secretsmanager_secret_rotation: support managed secrets #34180

Merged
merged 3 commits into from
Nov 1, 2023

Conversation

jar-b
Copy link
Member

@jar-b jar-b commented Oct 31, 2023

Description

This change makes the rotation_lambda_arn argument optional, allowing for use cases where secrets are managed by AWS and do not require a custom lambda function ARN to be specified.

Relations

Closes #34108

References

Output from Acceptance Testing

% make testacc PKG=secretsmanager TESTS=TestAccSecretsManagerSecretRotation_
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/secretsmanager/... -v -count 1 -parallel 20 -run='TestAccSecretsManagerSecretRotation_'  -timeout 360m

--- PASS: TestAccSecretsManagerSecretRotation_basic (314.98s)
--- PASS: TestAccSecretsManagerSecretRotation_duration (315.52s)
--- PASS: TestAccSecretsManagerSecretRotation_scheduleExpression (438.06s)
--- PASS: TestAccSecretsManagerSecretRotation_scheduleExpressionHours (453.56s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/secretsmanager     456.821s

Copy link

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 size/L Managed by automation to categorize the size of a PR. documentation Introduces or discusses updates to documentation. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. service/secretsmanager Issues and PRs that pertain to the secretsmanager service. and removed size/L Managed by automation to categorize the size of a PR. labels Oct 31, 2023
@terraform-aws-provider terraform-aws-provider bot added the prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. label Oct 31, 2023
@jar-b jar-b force-pushed the f-aws_secretsmanager-managed-rotation branch from 4c2ea4b to ec7bbc1 Compare October 31, 2023 14:57
This change makes the rotation_lambda_arn argument optional, allowing for use
cases where secrets are managed by AWS and do not require a custom lambda function
ARN to be specified.
@jar-b jar-b force-pushed the f-aws_secretsmanager-managed-rotation branch from ec7bbc1 to 0a76c42 Compare October 31, 2023 14:57
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=TestAccSecretsManagerSecretRotation_' PKG=secretsmanager ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/secretsmanager/... -v -count 1 -parallel 2  -run=TestAccSecretsManagerSecretRotation_ -timeout 360m
=== RUN   TestAccSecretsManagerSecretRotation_basic
=== PAUSE TestAccSecretsManagerSecretRotation_basic
=== RUN   TestAccSecretsManagerSecretRotation_scheduleExpression
=== PAUSE TestAccSecretsManagerSecretRotation_scheduleExpression
=== RUN   TestAccSecretsManagerSecretRotation_scheduleExpressionHours
=== PAUSE TestAccSecretsManagerSecretRotation_scheduleExpressionHours
=== RUN   TestAccSecretsManagerSecretRotation_duration
=== PAUSE TestAccSecretsManagerSecretRotation_duration
=== CONT  TestAccSecretsManagerSecretRotation_basic
=== CONT  TestAccSecretsManagerSecretRotation_duration
--- PASS: TestAccSecretsManagerSecretRotation_duration (62.68s)
=== CONT  TestAccSecretsManagerSecretRotation_scheduleExpressionHours
--- PASS: TestAccSecretsManagerSecretRotation_basic (71.07s)
=== CONT  TestAccSecretsManagerSecretRotation_scheduleExpression
--- PASS: TestAccSecretsManagerSecretRotation_scheduleExpressionHours (87.40s)
--- PASS: TestAccSecretsManagerSecretRotation_scheduleExpression (87.63s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/secretsmanager	166.113s

@jar-b jar-b merged commit 6e888ae into main Nov 1, 2023
44 checks passed
@jar-b jar-b deleted the f-aws_secretsmanager-managed-rotation branch November 1, 2023 13:29
@github-actions github-actions bot added this to the v5.24.0 milestone Nov 1, 2023
github-actions bot pushed a commit that referenced this pull request Nov 1, 2023
Copy link

github-actions bot commented Nov 2, 2023

This functionality has been released in v5.24.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!

Copy link

github-actions bot commented Dec 3, 2023

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 3, 2023
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. prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. service/secretsmanager Issues and PRs that pertain to the secretsmanager service. 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.

[Enhancement]: Support managed rotation for AWS Secrets Manager
3 participants