swarm-bao granter stops retrying a rejected bootstrap token
swarm-bao-granter-role exits 4 when the store is unsealed but refuses the bootstrap token, and Restart=on-failure retried that every 30s for as long as the token file existed. RestartPreventExitStatus=4 makes that permanent failure leave the unit failed once. Exit 1 (store sealed or unreachable) keeps retrying. On deploy: the unit goes red once instead of looping every 30s. The stale token on muede-lpt2 still needs the operator step (remove it or mint a fresh one); this does not clear it.
This commit is contained in:
parent
de68f175b5
commit
9a65643769
3 changed files with 18 additions and 0 deletions
|
|
@ -40,6 +40,11 @@ the bootstrap commands. It never skips. `swarm-bao-granter-role` skips while
|
|||
the token file is absent, which is the steady state afterwards; the token's
|
||||
TTL means a forgotten file expires rather than lingering.
|
||||
|
||||
A sealed or unreachable store makes the unit retry every 30 s. A store that
|
||||
refuses the token (expired, revoked, or missing the `bao-bootstrap` policy)
|
||||
makes it exit 4 and stay `failed` with the one-time step in its log; mint a
|
||||
fresh token or remove the file, then restart it.
|
||||
|
||||
After that, a new or changed `swarm-*` grant needs no operator step: the unit
|
||||
that writes it changes, and the deploy restarts it. A root step comes back only
|
||||
when the granter itself needs a path it lacks, such as a new mount.
|
||||
|
|
|
|||
Loading…
Reference in a new issue