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 usage_mode to support short-lived certificates #27496

Merged
merged 19 commits into from
Oct 27, 2022

Conversation

bschaatsbergen
Copy link
Member

@bschaatsbergen bschaatsbergen commented Oct 26, 2022

Description

Add a new argument: usage_mode to resource: aws_acmpca_certificate_authority to support short-lived certificates.

Relations

Closes #27491

References

Output from Acceptance Testing

$ make testacc TESTS=TestAccACMPCACertificateAuthority_basic PKG=acmpca
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/acmpca/... -v -count 1 -parallel 20 -run='TestAccACMPCACertificateAuthority_basic'  -timeout 180m
=== RUN   TestAccACMPCACertificateAuthority_basic
=== PAUSE TestAccACMPCACertificateAuthority_basic
=== CONT  TestAccACMPCACertificateAuthority_basic
--- PASS: TestAccACMPCACertificateAuthority_basic (31.02s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/acmpca     31.087s

$ make testacc TESTS=TestAccACMPCACertificateAuthority_usageMode PKG=acmpca
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/acmpca/... -v -count 1 -parallel 20 -run='TestAccACMPCACertificateAuthority_usageMode'  -timeout 180m
=== RUN   TestAccACMPCACertificateAuthority_usageMode
=== PAUSE TestAccACMPCACertificateAuthority_usageMode
=== CONT  TestAccACMPCACertificateAuthority_usageMode
--- PASS: TestAccACMPCACertificateAuthority_usageMode (31.39s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/acmpca     31.455s

$ make testacc TESTS=TestAccACMPCACertificateAuthorityDataSource_ PKG=acmpca 
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/acmpca/... -v -count 1 -parallel 20 -run='TestAccACMPCACertificateAuthorityDataSource_'  -timeout 180m
=== RUN   TestAccACMPCACertificateAuthorityDataSource_basic
=== PAUSE TestAccACMPCACertificateAuthorityDataSource_basic
=== RUN   TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL
=== PAUSE TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL
=== CONT  TestAccACMPCACertificateAuthorityDataSource_basic
=== CONT  TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL
--- PASS: TestAccACMPCACertificateAuthorityDataSource_basic (32.70s)
--- PASS: TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL (32.72s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/acmpca     32.810s

@github-actions
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 service/acmpca Issues and PRs that pertain to the acmpca service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. needs-triage Waiting for first response or review from a maintainer. size/M Managed by automation to categorize the size of a PR. labels Oct 26, 2022
@bschaatsbergen bschaatsbergen changed the title Add usage_mode to support short lived certificates Add usage_mode to support short-lived certificates Oct 26, 2022
@bschaatsbergen bschaatsbergen marked this pull request as ready for review October 26, 2022 21:03
@github-actions github-actions bot added the documentation Introduces or discusses updates to documentation. label Oct 26, 2022
@bschaatsbergen
Copy link
Member Author

bschaatsbergen commented Oct 26, 2022

Could the respective reviewer please run all the respective tests, I've just ran _basic and _usageMode to prevent cost blowout on my playground account. Thanks.

@ewbankkit ewbankkit removed the needs-triage Waiting for first response or review from a maintainer. label Oct 27, 2022
@github-actions github-actions bot added size/L Managed by automation to categorize the size of a PR. and removed size/M Managed by automation to categorize the size of a PR. labels Oct 27, 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=TestAccACMPCACertificateAuthority_basic\|TestAccACMPCACertificateAuthority_usageMode\|TestAccACMPCACertificateAuthority_deleteFromActiveState\|TestAccACMPCACertificateAuthorityDataSource_' PKG=acmpca ACCTEST_PARALLELISM=3
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/acmpca/... -v -count 1 -parallel 3  -run=TestAccACMPCACertificateAuthority_basic\|TestAccACMPCACertificateAuthority_usageMode\|TestAccACMPCACertificateAuthority_deleteFromActiveState\|TestAccACMPCACertificateAuthorityDataSource_ -timeout 180m
=== RUN   TestAccACMPCACertificateAuthorityDataSource_basic
=== PAUSE TestAccACMPCACertificateAuthorityDataSource_basic
=== RUN   TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL
=== PAUSE TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL
=== RUN   TestAccACMPCACertificateAuthority_basic
=== PAUSE TestAccACMPCACertificateAuthority_basic
=== RUN   TestAccACMPCACertificateAuthority_usageMode
=== PAUSE TestAccACMPCACertificateAuthority_usageMode
=== RUN   TestAccACMPCACertificateAuthority_deleteFromActiveState
=== PAUSE TestAccACMPCACertificateAuthority_deleteFromActiveState
=== CONT  TestAccACMPCACertificateAuthorityDataSource_basic
=== CONT  TestAccACMPCACertificateAuthority_usageMode
=== CONT  TestAccACMPCACertificateAuthority_basic
--- PASS: TestAccACMPCACertificateAuthority_usageMode (22.13s)
=== CONT  TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL
--- PASS: TestAccACMPCACertificateAuthority_basic (22.35s)
=== CONT  TestAccACMPCACertificateAuthority_deleteFromActiveState
--- PASS: TestAccACMPCACertificateAuthorityDataSource_basic (23.32s)
--- PASS: TestAccACMPCACertificateAuthorityDataSource_s3ObjectACL (20.72s)
--- PASS: TestAccACMPCACertificateAuthority_deleteFromActiveState (21.43s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/acmpca	47.820s

@ewbankkit
Copy link
Contributor

@bschaatsbergen Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit 1de12b2 into hashicorp:main Oct 27, 2022
@github-actions github-actions bot added this to the v4.37.0 milestone Oct 27, 2022
@github-actions
Copy link

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

@bschaatsbergen bschaatsbergen deleted the acmpca-short-lived-certs branch October 28, 2022 08:52
@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 Nov 28, 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/acmpca Issues and PRs that pertain to the acmpca 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
Development

Successfully merging this pull request may close these issues.

r/aws_acmpca_certificate_authority: SHORT_LIVED_CERTIFICATE mode
2 participants