Commit graph

7 commits

Author SHA1 Message Date
3a0ec9740e feat(release): publish to public devbox-dist repo (no-token curl|sh) 🌐📦
Some checks are pending
CI / vet-build-test (push) Waiting to run
Private code stays private; the public shoemoney/devbox-dist repo carries only the
install scripts + release binaries as release assets, so a clean Pi/box can:
  curl -fsSL .../devbox-dist/releases/download/latest/install.sh | sh
with no auth. release.sh now targets devbox-dist (tags hang off its branch),
uploads install.sh/install.ps1 alongside the binaries, and rewrites SHA256SUMS to
the de-versioned asset names so shasum -c matches. install.sh/install.ps1/README
point at the new public URLs.
2026-06-23 18:12:09 -05:00
9b1165a49a feat(release): arm64/arm targets + Forgejo release one-shot + CI workflows 📦🤖
Some checks are pending
CI / vet-build-test (push) Waiting to run
- build-release.sh: add linux/arm64 (Raspberry Pi!) + linux/arm targets — the
  curl|sh install on a clean Pi needs a real arm64 asset to download.
- scripts/release.sh: one-shot local release. Cross-compiles, then creates/updates
  the Forgejo release and uploads de-versioned assets (devbox_<os>_<arch>) that
  install.sh fetches directly. No CI runner required.
- .forgejo + .github CI workflows: go vet + build + test -race on push/PR;
  on vX.Y.Z tag, build-release + publish. GitHub's runs on hosted runners today.
- docker-compose: pull the published hub image by default; --build for local source.
2026-06-23 13:31:54 -05:00
be4a30ef5d test: scripts/dashboard-fleet-verify.sh — live flow events on real hardware 🧪📊
Proves the dashboard SSE flow stream end-to-end on an isolated arm64 hub:
captures /api/events, then a device join + publish produce live 'join' and
'push' flow events on the stream. Green on .13: join(ubuntu) + push(team,
1 chunk, 15B, new_head) both streamed. Self-cleans; never touches the live .10.
2026-06-23 12:36:57 -05:00
2f51f2c463 test(M8a): scripts/m8a-invite-fleet-verify.sh — cross-machine invite proof 🧪🌐
Re-runnable two-host fleet test against an ISOLATED hub (never the live
.10). Owner on one Pi invites bob editor; a device on ANOTHER Pi redeems
via the join PoP flow, lands as bob/editor, and pushes an edit (snapshots
1->2). Bakes in the 64-char-token gotcha (randomBearer = 32 bytes; a {32}
grep truncates it -> 401). Green on .13+.15 arm64; self-cleans both hosts.
2026-06-23 11:37:11 -05:00
0d8b2505da test(M8): scripts/verify-hub-migration.sh — prove a migration on real hub data 🧪🛡️
Reusable safety gate: copies the live hub DB (all 3 WAL files — copying
only .db migrates an EMPTY db and false-passes), runs the new binary's
migration in isolation, and asserts version advanced, backup made, and
counts preserved (devices/shares/chunks equal, snapshots may grow from
backfill, no orphan heads). Live hub never touched. Re-run before every
hub upgrade; adjust the INVARIANTS block per migration. Already green on
the real .10 data: 13 dev / 12 share / 16 chunk preserved, 3 heads repaired.
2026-06-23 11:01:42 -05:00
88aa53064f feat(M7): periodic rescan fallback for dead/limited watchers 🔁🍓
The v1 daemon only re-syncs a mount on a watcher event or a hub event. If the
watcher can't start (inotify max_user_instances/max_user_watches exhausted on a
big Pi tree — PRD risk #1) the mount silently stops pushing local edits.

Add a 60s per-mount rescan ticker that nudges a sync regardless, so a mount
reconverges even with no working watcher. Watcher-start failure now logs the
fallback + points at 'devbox doctor' instead of going quiet.

Fleet-verified on linux/arm64: with fs.inotify.max_user_instances=0 (watcher
dead) a local edit still propagated to a peer via the rescan tick.
scripts/m7-fleet-verify.sh exercises the full M7 surface + this rescan path.
2026-06-23 01:53:24 -05:00
38766fdcd5 feat(M7): SSE reconnect backoff + share-name validation 🛡️
- daemon: exponential backoff (1s→30s) + ±25% jitter on SSE reconnect so a fleet
  that drops together doesn't reconnect in lockstep; a long-lived stream resets it
- hub: ValidateShareName rejects path separators, traversal, control/non-ASCII
  chars, reserved Windows device names (CON/NUL/COM1…), and case-clashes with an
  existing share (Foo vs foo would collide on case-insensitive filesystems)
- tests for both
2026-06-23 01:26:04 -05:00