swarmctl setup status: show the pending bootstrap re-run for the pods' login
`swarm-bao-k8s-jwt-policy` exits 0 when the bootstrap token lacks `sys/auth/jwt-k8s`, so a store set up before the node looked fine in `swarmctl setup status`: the unit is active and nothing marks the root-only `swarmctl bao grant-bootstrap` re-run as pending. The unit now keeps /run/swarm-bao-k8s-jwt-pending while it stays off and removes it before it writes the mount's config. `setup status` reads the file and shows step 3, "granter bootstrapped", as not done, naming the verb. `module-eval-k8s` pins the order of the touch, the exit and the removal.
This commit is contained in:
parent
3c0f67e23d
commit
6acf1012cb
1 changed files with 80 additions and 0 deletions
|
|
@ -162,6 +162,11 @@ The grant adds `sys/auth/jwt-k8s` to the bootstrap policy, and the restart lets
|
|||
`swarm-bao-granter-role` enable the mount and `swarm-bao-k8s-jwt-policy` write
|
||||
the pods' login. Until both have run, the pods can't log in.
|
||||
|
||||
Until the grant runs, `swarmctl setup status` shows step 3, "granter
|
||||
bootstrapped", as not done. `swarm-bao-k8s-jwt-policy` exits 0 and keeps
|
||||
`/run/swarm-bao-k8s-jwt-pending` while the bootstrap token lacks the grant, and
|
||||
the status reads that file.
|
||||
|
||||
## Validation
|
||||
|
||||
`module-eval-k8s` compares an all-local host with the option on against the
|
||||
|
|
|
|||
Loading…
Reference in a new issue