feat(azure): add explicit_max_ttl for azure roles - #2438
Conversation
Change introduced in hashicorp#2438
|
Unrelated to this PR, but the Vault API is returning the role's GUID ( I think this may be the result of an Azure API change, as I'm seeing the same behavior for both Vault 1.16 and 1.19. |
Hi @gsantos-hc, we recently merged a fix for this issue to the Azure Secrets engine here: hashicorp/vault-plugin-secrets-azure#233 This reverts the GUID / Role name to the original behavior from 1.15.5 and should resolve the issue you're seeing above |
Add support for configuring `explicit_max_ttl` for Azure Secrets roles. This field was released as part of Azure Secrets plugin v0.20.0, incorporated into Vault 1.18.0 and later. Note that the field is configured as an integer to align with how other resources throughout the provider handle TTL fields. Configuring it to a seconds-based integer avoids Terraform flagging drifts between the seconds returned from Vault's API and the Terraform string-based configuration.
Change introduced in hashicorp#2438
5a03519 to
3ae75de
Compare
|
Force-pushed to:
|
|
@Zlaticanin When you get a chance, would you be able to review? I added some callouts throughout the PR already. |
Per feedback in hashicorp#2438, revert the explicit_max_ttl field in the `azure_secret_backend_role` resource to a string type for internal consistency within the resource. Fix deletion acceptance test code.
vinay-gopalan
left a comment
There was a problem hiding this comment.
Looking great! Had a couple small comments, should be good to get in soon after; thanks for working on this!
Invert when tests for `explicit_max_ttl`, `tags`, and `sign_in_audience` run. Previously, these tests were run only when the API did _not_ support the attributes, which was a likely oversight. Addresses feedback in hashicorp#2438.
Addresses feedback in hashicorp#2438.
vinay-gopalan
left a comment
There was a problem hiding this comment.
Thanks for the PR and your patience with the feedback! LGTM
Description
Update the
azure_secret_backend_roleresource to add support forexplicit_max_ttlfor Azure Secrets roles. This field was introduced as part of Azure Secrets plugin v0.20.0, incorporated into Vault 1.18.0 and later.Closes #2434.
Checklist
Output from acceptance testing:
IMPORTANT NOTE: I applied the patch below to work around the acceptance test failing on
main:Acceptance test patch
Community Note