Skip to content

Workload identity - Vault token renewal runs every 30 seconds #25812

Open
@nicoche

Description

@nicoche

Hey!

Nomad version

Nomad 1.9.6 (also seemed to happen on 1.10)

Issue

Hey!

We use use Vault secrets in our job spec templates. We recently upgraded to Nomad 1.9 and Workload Identity.

We have an issue where it seems that nomad-clients are trying too often to create Vault tokens. From what I read of the documentation, nomad-client is supposed to create a token when first booting an alloc, with the TTL specified by the Identity. Then, it would renew the token when we are halfways through the TTL.

From what I read of the code, an initial TTL of 30s is specified here https://github.com/hashicorp/nomad/blob/main/client/allocrunner/taskrunner/vault_hook.go#L292 but then, I couldn't understand where the TTL specified by the workload identity is enforced. It seems to me that the token is renewed every 30s/2=15s.

Do you think this is a bug? If no, do you know what could be happening?

Metadata

Metadata

Assignees

Type

No type

Projects

Status

Triaging

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions