Skip to content

fix(launch): --pinned prunes superseded images after a healthy up (gh-#441) - #443

Merged
genwave-radio merged 2 commits into
mainfrom
fix/gh-441-pinned-image-prune
Aug 9, 2026
Merged

fix(launch): --pinned prunes superseded images after a healthy up (gh-#441)#443
genwave-radio merged 2 commits into
mainfrom
fix/gh-441-pinned-image-prune

Conversation

@genwave-radio

Copy link
Copy Markdown
Collaborator

Closes #441 — today's disk-full incident, made structurally unrepeatable before tonight's Pi 4 run. 🧹

What ships

  • launch.sh (pinned flow only): after persist_compose_file on the success path — docker image prune -af --filter until=168h (keeps everything in use + ~last week of releases for instant rollback) + docker builder prune -af (a --pinned box never builds). Best-effort: hygiene never fails a launch that already succeeded. Every failure path bails via preflight_fail before the prune line, so a failed upgrade leaves the previous images — the ones still running — untouched.
  • --dry-run plan parity: both prune steps appear in the plan, after up -d.
  • DEPLOYMENT.md: the under-the-hood block + a paragraph on why (with today's 46GB number).
  • Specs (Gh441_…, Story201 harness pattern, no docker daemon needed): retention filter present, builder prune present, prune ordered after up, and the dev flow contains no prune at all (it builds from source — pruning there would eat a developer's build layers).

Verification

  • Red-checked: 3/4 specs fail against pre-fix launch.sh (the dev-flow-absence spec correctly passes both ways).
  • --pinned --dry-run plan verified by hand; bash -n clean; tools/check-doc-drift.sh green; full suite 3,631 passed / 0 failed, 0 warnings.
  • The prune command itself is the exact one already proven live on the demo box today (43.9GB reclaimed with the stack running).

Note for the Pi 4

launch.sh runs from the repo checkout, not from images — once this merges, the Pi 4's fresh clone has it from boot #1. No release needed.

Nothing ever pruned old release tags — 46GB of dead images filled the
demo box's 75GB disk mid-deploy (2026-08-09, db PANIC on full device
during db/34); an SD-card Pi hits the wall far sooner. Success path
only (every failure bails via preflight_fail first), best-effort,
until=168h keeps in-use + ~last week of releases for instant rollback;
builder cache goes entirely (a --pinned box never builds). Dev flow
untouched. Closes #441
@genwave-radio
genwave-radio merged commit 6df5695 into main Aug 9, 2026
11 checks passed
@genwave-radio
genwave-radio deleted the fix/gh-441-pinned-image-prune branch August 9, 2026 20:00
@github-actions github-actions Bot locked and limited conversation to collaborators Aug 9, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

launch.sh --pinned: prune superseded release images after a healthy up — 46GB of dead tags filled the demo box mid-deploy

1 participant