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

Added data source for dynamic secrets #868

Merged
merged 2 commits into from
Jun 28, 2024

Conversation

maxcoulombe
Copy link
Contributor

🛠️ Description

Added the ability to "open" dynamic secrets, that is create a new credential instance on every run.

Demo (all sensitive values have been revoked):

terraform_dynamic_secrets.mp4

Open question:

  • Can we or should we not save anything in the statefile if they are regenerated on every run? The behavior is correct, it's just that the statefile diff is noisy and doesn't provide value

🏗️ Acceptance tests

  • Are there any feature flags that are required to use this functionality?
  • Have you added an acceptance test for the functionality being added?
  • Have you run the acceptance tests on this branch?

Output from acceptance testing:

$ 15:30:09 max:~/projects-cloud/terraform-provider-hcp$ make testacc TESTARGS='-run=TestAcc_dataSourceVaultSecretsDynamicSecret'
(...)
=== RUN   TestAcc_dataSourceVaultSecretsDynamicSecret
--- PASS: TestAcc_dataSourceVaultSecretsDynamicSecret (5.61s)
PASS
ok  	github.com/hashicorp/terraform-provider-hcp/internal/provider/vaultsecrets	5.622s
(...)
...

@maxcoulombe maxcoulombe requested review from a team as code owners June 20, 2024 19:32
Copy link
Member

@austingebauer austingebauer left a comment

Choose a reason for hiding this comment

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

LGTM otherwise!

* fix doc


* fix comment


* changelog


* fix doc


* adjust doc


* fix bad copy-paste in the template doc file
@maxcoulombe maxcoulombe force-pushed the vault-26395-hvs-dynamic-secret-data-source branch from 79f9022 to 575b0e9 Compare June 21, 2024 11:39
@maxcoulombe maxcoulombe merged commit e47cc9f into main Jun 28, 2024
6 checks passed
@maxcoulombe maxcoulombe deleted the vault-26395-hvs-dynamic-secret-data-source branch June 28, 2024 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants