Repository navigation
fix: only wait on the machines an update brings up - #66
Merged
riadelhajjaji-scality merged 2 commits intoNov 4, 2026
Merged
Conversation
riadelhajjaji-scality
requested review from
TeddyAndrieux,
anthony-treuillier-scality and
m4nch0t
and removed request for
m4nch0t
October 29, 2026 11:08
riadelhajjaji-scality
marked this pull request as draft
November 3, 2026 08:22
`wait-for-boot` was a single command checking every machine, re-run whenever any instance changed. Removing one node therefore asked cloud-init again on machines that had been in use for an hour. Each machine now gets its own `wait-for-boot-<machine>`, triggered by its own instance only. The bastion setup still waits on all of them. The status is still asked through `sudo -n` first (#65), but only if sudo allows it, checked with `sudo -l`. Otherwise it falls back to asking as the SSH user, which works on a freshly booted machine. The fallback covers ARTESCA machines installed before artesca-os was allowed to run `cloud-init status --wait` through sudo (scality/artesca#5818). It is meant to go once those versions are no longer spawned.
riadelhajjaji-scality
force-pushed
the
bugfix/MK8S-519-wait-only-on-new-machines
branch
from
November 3, 2026 13:33
943d9ee to
4b3edc9
Compare
riadelhajjaji-scality
marked this pull request as ready for review
November 3, 2026 13:35
riadelhajjaji-scality
marked this pull request as draft
November 4, 2026 08:36
riadelhajjaji-scality
marked this pull request as ready for review
November 4, 2026 08:38
Only new machines are waited on, and the SSH user can read the status of a freshly booted one. That is also the only way on ARTESCA machines installed before artesca-os was allowed to run cloud-init through sudo (scality/artesca#5818). When asking as the SSH user fails, the status is asked again through `sudo -n`, if `sudo -l` says it is allowed. Otherwise the first answer is reported, so that a refusal is not mistaken for a bad boot.
TeddyAndrieux
approved these changes
Nov 4, 2026
riadelhajjaji-scality
deleted the
bugfix/MK8S-519-wait-only-on-new-machines
branch
November 4, 2026 14:32
riadelhajjaji-scality
restored the
bugfix/MK8S-519-wait-only-on-new-machines
branch
November 4, 2026 17:19
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Updating a platform waits on every machine again, including the ones the update left alone:
On Rocky 9, cloud-init ships a tmpfiles rule that keeps
/run/cloud-initto root (0700), and systemd runs every tmpfiles rule again whenever a package ships one. Once something has been installed,cloud-init statuscan no longer read its runtime config as the SSH user (canonical/cloud-init#6680).#65 (released in v3.2.3) asks through
sudo -nonly. That fixed MetalK8sbootstrap-restorebut broke ARTESCA spawns from snapshots of clusters installed before scality/artesca#5818, whereartesca-osis not allowed to run cloud-init through sudo:(ARTESCA nightly
upgrade-from-snapshots (single-node, previous, 4.3.4), run 41751747994. The same job passed on v3.2.2.)What it does
wait-for-boot-<machine>, triggered by that machine's instance only. An update now waits only on the machines it brings up, which are freshly booted, and leaves the others alone. The bastion setup still waits on all of them.sudo -n, ifsudo -lsays it is allowed. Otherwise the first answer is reported, so a sudo refusal is not mistaken for a bad boot.Once ARTESCA versions without scality/artesca#5818 are no longer spawned, the first attempt goes and the status is only asked through sudo.
Since the waits are renamed, updating a platform spawned before this change waits once more on every machine.
Once merged, a GA patch release (
v3.2.4) movesv3, so callers get the fix without changing anything on their side.Closes MK8S-519