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

secret/kvv2: fix drift detection when disable_read is enabled #2039

Merged
merged 3 commits into from
Oct 9, 2023

Conversation

fairclothjm
Copy link
Contributor

@fairclothjm fairclothjm commented Oct 5, 2023

Description

This PR fixes a bug with disable_read for the kvv2 secrets resource. When disable_read is true we remove the computed data keys from the diff. Otherwise, we will report drift because they were never set but the provider expects them to be because they are computed fields.

Closes #1668

Checklist

  • Added CHANGELOG entry (only for user-facing changes)
  • Acceptance tests where run against all supported Vault Versions

Output from acceptance testing:

$ make testacc TESTARGS='-run=TestAccXXX'

...

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" comments, they generate extra noise for pull request followers and do not help prioritize the request

@github-actions github-actions bot added the size/M label Oct 5, 2023
@fairclothjm fairclothjm requested a review from a team October 5, 2023 15:36
@fairclothjm fairclothjm added this to the 3.21.0 milestone Oct 9, 2023
Copy link
Contributor

@vinay-gopalan vinay-gopalan left a comment

Choose a reason for hiding this comment

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

LGTM and manual testing also passes 😄 Thanks for working on this!

@fairclothjm fairclothjm merged commit f8375be into main Oct 9, 2023
5 checks passed
@fairclothjm fairclothjm deleted the VAULT-13021/kvv2/disable-read branch October 9, 2023 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

disable_read argument does not work with vault_kv_secret_v2
2 participants