jason.woltje
0430c7dc32
fix(release,task,auth): health-reason review round: the worker credential check reads the auth file path as compose does (a leading ~ is $HOME, a relative path is from the checkout, a named volume is undecided), treats COMPOSE_ENV_FILES and docker-compose.override.yaml|yml as undecided like .env, and leaves the credential not checked when this user can't read the auth file (EACCES, EPERM) instead of refusing; a key variable that is only spaces is no credential, as in pi; a compose.yaml that can't be read or parsed gives fixed words, never its path or text; release.sh's reason with no run id comes from the new scripts/health-reason.mjs (the last refusal line, prefix dropped, redacted, withheld when it holds an environment value) and says "gave no run id"; the fault-injection and recursion-guard comments are back; tests cover the tilde path, COMPOSE_ENV_FILES, an unreadable auth file, a blank key, a compose warning line in a failed run's stderr, and the redacted and withheld reason; docs/TOOLS.md names each undecided case ( #1873 , lane health-reason)
2026-11-20 15:31:59 -06:00
jason.woltje
1433686d50
feat(release,task,auth,runs,plugins): health-reason: a failed release health check prints its run id and one plain reason before release: refusing activate: health check failed: the cause line mosaic-task show now prints for a run that did not succeed (a runner reason in words, else one redacted line from the run's stderr.txt read through the new readRunText), or, when the runner refused before a run record, its own refusal line, redacted. A pi run checks before its run directory exists that the worker container compose starts holds a credential for config execution.provider: names and types from the PI_AUTH_FILE compose mounts and the key variables compose passes with a value, judged by pi-ai's own checkAuth on placeholders (packages/plugins/harness/pi/worker-credential.mjs), so no provider list is kept; with none it refuses exit 3 naming the provider, what the container has and what to do; when it can't decide (COMPOSE_FILE, an override or .env, an env_file, an unknown provider) it says so and the run goes ahead. auth.sh status adds one line for the default run's provider and credential. Tests in test-task, test-release, test-auth and runs.test; docs/TOOLS.md ( #1873 , lane health-reason)
2026-11-20 15:14:07 -06:00
jason.woltje
8e9b05de8d
feat(release): pi-unpin S5: package.json gives pi the range >=0.85.1 and the lock still resolves 0.85.1; the image tag is mosaic-poc-agent:<lock version>-r<RELEASE>, built by scripts/image-tag.mjs from package-lock.json for common.sh, mosaic-task.mjs, the gate's lane-image.mjs, test-task.sh and test-auth.sh, never from the package.json string; scripts/pi-fit-image.mjs runs the fit check on the pi the lock resolves, as npm ci installed it, before every image build (build_image in common.sh for build.sh, release.sh package and verify.sh, and the gate's prepareImage), so an unfit locked pi fails the build; it runs on the host because docker build's seccomp refuses bwrap; agent-host-dev.sh records pi --version for its banner and no longer refuses on version; docs match ( #1873 , lane pi-unpin-s5)
2026-11-20 08:34:47 -06:00
jason.woltje
9fd16b9739
feat(release): recursion guard for the health gate; run-task drift warning; M20 packages/* decision recorded ( #39 )
...
- release.sh health gate runs with MOSAIC_ENSURE_SKIP=1: the gated task run
cannot re-enter release self-determination
- run-task.sh warns on release drift instead of silently using a stale image
- ROADMAP: M20 decision recorded (packages/* monorepo at usurpation,
continuity-first); restructure sequenced as M20 phase 1
Closes #39
2026-09-03 15:58:46 -05:00
jason.woltje
db330c12c7
feat(release): self-determination - ensure at launch, drift warnings, M20 packages/* decision ( #38 )
...
- release.sh ensure: aligned no-op; drift -> package-if-needed + health-gated
activate (M3 gate-then-flip, automated)
- ensure_release_aligned in common.sh: invoked by hello/verify/agent;
MOSAIC_ENSURE_SKIP guards recursion; run-task warns on drift without
auto-aligning (workers/suites never trigger builds or model gates)
- ROADMAP: M20 decision recorded - v2 adopts packages/* monorepo at usurpation
- BUILD-LOG Phase 20 + tool-race process note
Live-verified: post-reset pointer loss auto-restored via health-gated
ensure; drift warning fires on desired-version bump; idempotent no-op on
aligned state.
Closes #38
2026-09-03 14:42:09 -05:00
jason.woltje
a947db7bfd
feat(release): package/activate/rollback/status with health gate ( #11 )
...
- activate: image-presence pre-check + M2 task-runner health gate
(tasks/hello-marker.json exact marker) before atomic pointer replace
(tmp+rename); every attempt appended to activation-log.jsonl
- --fault-injection flips the health expectation to prove the refusal path
- rollback: health-gated re-activation of the previous activated imageTag
from the log; refuses when the image is gone or no previous exists
- status: release, tag, pointer, recent log; safe on empty state
- state lives under <dataRoot>/state/ (config-independent, reset-scoped)
Verified: activate OK; fault-injected refuse with pointer unchanged;
rollback-without-previous refuse.
Closes #11
2026-09-02 20:20:32 -05:00