4 Commits

Author SHA1 Message Date
eust-w
c5a6c6160d 🚀 Deploy WishForge to the POC cluster, with check Pods and daily backups
- cluster-poc.mjs: image (in-cluster Kaniko), bootstrap, secrets, apply,
  migrate --rehearsal|--final, public HTTPS entry, backup and restore
- One restricted Pod (platform, executor, Runner, PostgreSQL, Temporal,
  MinIO, Caddy, backup) listening only on loopback except Caddy
- Protected checks run in per-workspace check Pods; cancellation during
  start-up now always removes them
- Daily snapshots on the node (consistent dump with row counts, Temporal
  online backup), copied to the Mac by launchd with SHA-256 checks and a
  notification on failure; restore verified on the rehearsal copy
- Downloads and uploads survive the Mac's lossy link to the cluster
- Local public entry, evidence isolation labels, acceptance records

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-01 16:27:07 +08:00
eust-w
3623d318af ✨ Sandbox the local POC's protected checks and installations on macOS, by operator opt-in
In the development host mode, protected checks and dependency
installations ran directly as the operator. They run the agent's code:
a test it wrote could read the home directory's secrets, reach the
network, or plant Git configuration that the trusted Git commands after
it would execute.

With WF_HOST_CHECK_SANDBOX=true they run under Seatbelt instead. File
contents in the home directory are unreadable except the command's own
directory and the paths the operator lists; it may write only there,
in the caches the operator lists and in a temporary directory of its
own, never in a .git directory. Only installations reach the network;
checks may use loopback ports by opt-in, for test suites that start
local servers. The platform's own ports (control plane, Temporal and
its web UI, database, object storage, provisioner, Git service, IDE,
console) stay blocked in any case: the local start lists them from
their configured addresses. Checks get no answer from the keychain,
and a command whose home is the executor's (holding its credentials)
gets a private one. A sandbox that cannot start leaves the run waiting
on infrastructure; verification evidence records checkSandbox.

scripts/check-host-check-sandbox.ts checks all of this on the target
Mac, from outside the sandbox, then runs the POC's installation and
checks sandboxed on a recent droboticflow source. Enabled on the local
POC, a real wish passed through both, including a repair round for the
agent's own failing tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-26 10:10:47 +08:00
eust-w
87e01adb36 🔒 Space out local sign-in checks instead of locking out, and keep the dev server off the LAN
- Eight wrong passwords from anywhere on the network locked the only
  local administrator out for fifteen minutes, again and again. The
  password is 256 random bits, so the limit only has to bound the
  scrypt work: after eight failures, checks are spaced two seconds
  apart, globally, and a burst cannot run them at once.
- The launcher let the Next.js development server listen on the LAN,
  handing every visitor its source maps and hot-reload channel. Only
  the production build may now listen beyond loopback. A listener
  bound to one address is also checked for readiness there, and the
  banner shows the configured port.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 19:33:30 +08:00
eust-w
e0bccda4bf 🐛 Stop local services with everything they spawned, and test the scripts in CI
Stopping dev.mjs sent SIGTERM to each service and moved on, so a slow
service, or anything a service spawned (run workers, Next.js workers),
outlived it once the supervisor killed dev.mjs after 20 seconds. The
next start then found the old API answering and reused it: a rebuild
kept running old code.

- Each service runs in its own process group. Stopping signals the
  group, waits up to 10 seconds, then kills what remains.
- Under the LaunchAgent supervisor, a service already answering is
  refused instead of adopted (WF_LOCAL_REUSE_SERVICES=false).
- npm test, and so CI, now runs scripts/*.test.mjs. The POC check test
  that needs the Mac's Homebrew toolchain skips where there is none.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 17:31:51 +08:00