feat: kv-v2 generic secret metadata - #1239
Conversation
Set/Get KVv2 Secret Metadata. retrieve or set the following secrets metadata attributes * `cas_required`: force the version to be sent in order to create a new version. * `custom_metadata`: A map of string representing the custom_metadata for a secret * `delete_version_after`: Time duration (eg: `730h`) representing the secret's version lifetime. * `max_version`: int. Maxiumum number of versions for a given secret.
|
@benashz @jasonodonnell Hi team, could you review this by any chance ? Thanks ! |
|
@vfoucault I took a different route via #1311 but I think there is some overlap |
Hi there, I haven't been in details, but it seems that you are configuring global mount metadata, applying to all secrets, where I configure metadata per secret + custom metadata. I believe there are no overlap as metadata could be overwritten. In a scenario where eg. |
|
Would really like to see this merged! |
|
I'm interesting in this feature, any ideas about date, when this could be merged? |
|
Hi @vfoucault, thanks for contributing with this PR and apologies for the delay! In v3.7.0 of the TF Vault Provider we added dedicated KV V1 and V2 secret engine resources/datasources which support the latest individual V1 and V2 APIs respectively and which supersede the With that said, we do recognize a gap in our feature set with the demand for a KV V2 secret metadata resource. A PR for the resource is currently being tracked in #1687, and the code is compatible with the newer dedicated KV V2 Engine support. The feature is slated to be released as part of the v3.12.0 milestone. We're going to close this PR for now and move forward with the updated implementation, but please feel free to open another issue if you face any problems with the upcoming metadata resource feature. Thanks once again for bringing this to our attention! |
Added support for kv-v2 secret's metadata:
cas_required
custom_metadata
delete_version_after
max_versions
Thought
cas_requiredcan be set (via the http apioptionsblock), none of the above settings could be set with the regular resources.It might become handy to read/write the secret metadata, to set per secret these settings.
usage example:
resource
data source
Community Note
Relates to #491 to #1156
Release note for CHANGELOG:
Output from acceptance testing: