-
Notifications
You must be signed in to change notification settings - Fork 192
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
Vault Kubernetes auth role token is not renewed #309
Comments
@eikenb Tried with 0.13.1 with the change you mentioned. The token is still not renewed when it expires. The only difference is that now envconsul doesn't reload static secrets when they are changed (I was surprised to see such a change in behavior in a minor update, TBO), so if it only reads static secrets, it never fails. But once a dynamic secret is about to expire, envconsul tries to renew it and, if the token is already expired at this point, it starts to log 403s. |
Thanks for the followup @Dizeee.
Sorry, being a bit dense... Would you mind expanding on what you mean by static secrets here? Thanks. |
@eikenb By static I mean secrets stored in a KV backend (we use KV v2). And by dynamic - secrets that are generated and managed by Vault secret engines, like MySQL or RabbitMQ credentials. |
Thanks. Secrets stored using the KV values should always be monitored and kept up to date. The default is to check every 5 minutes. |
@eikenb 0.13.0 checked every few seconds, I guess it was a bug. It's not related to my issue anyway. |
Yeah. That was issue #310... the reason I released 0.13.1. :) |
Sorry for the red herring and back to the original issue @Dizeee... Re-reading your original post I've got 2 questions.
Thanks. |
@Dizeee Can you please check this issue in my fork? |
@skpratt @sarahethompson @eikenb and others is there any update to this issue or the candidate fixes above? ^^ this is a real drag on our usage of envconsul :( |
Envconsul version
envconsul v0.13.0 (c9c55c9)
Configuration
renew_token = true
should probably be redundant like with a plaintext token, as there's no agent involved. Anyway, it makes no difference and doesn't help to resolve the issue.Command
Debug output
For demo purpose I set the Vault Kubernetes role token initial TTL to 60 seconds. Max TTL is 1 hour, so it has no effect on the outcome. I also tried with different initial TTL, max TTL and period from a few minutes to a few hours, the result is always the same: once the initial TTL expires, envconsul starts to log 403s.
https://gist.github.com/dizeee/7bfa522a44ccab6852ecb8557b414eaf
Expected behavior
Vault token is renewed before its TTL expires. It would also be nice to rotate the token when max TTL is reached.
Actual behavior
403 errors appear in the log after the token TTL expires.
References
The text was updated successfully, but these errors were encountered: