-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Automatically renew the token used by the Vault CA provider #8560
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should [we] make this configurable or just always enabled.
Do the other providers auto-renew?
The other providers don't use a Vault token so there isn't a direct comparison. Renewing a token to extend the lease is pretty standard, though so I think there's a decent argument for it here, but there could also be a valid reason not to renew that I'm not seeing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! I think I am understanding this now. Mostly some minor suggestions for goroutine management and test cleanup.
I think the only real blocker is the handling of renewer.DoneCh()
.
I'm not sure why codecov is reporting that so many lines are not covered by tests, I confirmed they are.
@dnephin This is ready for another look when you get a chance, I addressed all the comments. |
422bd9b
to
1cd7c43
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, LGTM!
This PR adds logic to the Vault provider to renew the lease of the token automatically. It still needs a unit test, but I wanted to get feedback on whether we should make this configurable or just always enabled.