feat(registry): warm every StatefulSet image on the zot node before a rollout #23
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/zot-image-prepull"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Add
Job/zot-image-warm, an Argo CDSynchook in wave -1. It pulls every image of thezot-v2pod template onto the node that runszot-v2-0before wave 0 updates the StatefulSet. A bad or unpullable image fails the sync, and the old pod keeps serving.Why. On 2026-09-02 an image change rolled
zot-v2-0to an image the node could not pull. Nodes pullcodeberg.orgimages through zot itself; the direct fallback failed with 401 on a stale node PAT. The revert could not roll the Pending pod (OrderedReady). The registry was down for 40 minutes.How.
registry.sean.farm/image-warm: zot-v2and a requiredpodAffinityonkubernetes.io/hostname. When no pod carries the label (cold rebuild), the scheduler's self-affinity rule lets the pod run anywhere.Namespace/registrymoves to wave -1 so the hook has a namespace on a cold rebuild.--versionto the image entrypoint: the upstream image has/usr/local/bin/zot-linux-amd64, the seanfarm fork/usr/bin/zot.backoffLimit: 0,restartPolicy: Never,activeDeadlineSeconds: 600, no SA token, uid/gid 902, restricted security context, tiny resources.Guards. New
tests/zot-image-warm.sh(image sets equal, digest pins,IfNotPresent, wave placement, pin label on exactly the two templates, pod security,imagePullSecretsparity).tests/zot-binjovi-publisher.shrequires the identity labels as a subset of the pod labels.tests/zot-oidc-ui.shcounts hooks inside the registrar block only.Rollout note. This sync adds the pin label, so the first hook run is not pinned (the label reaches the live pod in wave 0). Both images are already cached on the zot node, so the one-time roll needs no pull. Pinning applies from the next sync on.
Docs.
docs/REGISTRY-AVAILABILITY.mdgains "Image warm-up before a rollout": the failure chain, wave and content rules, the one-sync label gap, the cold-rebuild limit (stale node PATs), and how to read a failed hook.https://claude.ai/code/session_01LeVatedQ4sCA1u6LHjo7B5