Skip to content

Vualt token renew doesn't retry on failure #2058

@ShayaSi

Description

@ShayaSi

If consul-template is configured to use vault token with a renew configuration, and the vault token renew fails once (for example the server is temporarily unreachable), it doesn't retry like intended.

2025-05-08T11:37:57.417Z [WARN] vault.token: failed to renew: context deadline exceeded
2025-05-08T11:37:57.417Z [WARN] vault.token: renewer done (maybe the lease expired)

After that it hangs.

Problem comes from the line:

serverErrCh <- err

The channel that is being written isn't buffered and there is no one reading from that channel for the special vault token watcher:

vaultTokenWatcher *watch.Watcher

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions