|
|
6d0453d8e3
|
feat(M6): versioning — log, restore, hub gc 🕰️
- devbox log <share>: hub GET /v1/log (meta.SnapshotLog newest-first), client.Log
- devbox restore <share> <snapshot> [path]: snapshot id == manifest blob hash, so
syncer.Restore fetches the old manifest, rewrites the file(s) (+deletes extras for
a whole-tree restore), and pushes -> itself a new reversible snapshot
- devbox-hub gc [--keep N]: prune snapshots beyond the newest N (never the head),
decrement chunk refcounts, sweep refcount<=0 chunks + manifest blobs from the store
- meta: SnapshotLog, ShareNames, DeletableSnapshots (rowid tiebreaker), DeleteSnapshot
(tx + refcount--), UnreferencedChunks, DeleteChunkRow
- tests: log order/limit, deletable keeps head+newest, refcount decrement, whole-tree
+ single-path restore, gc end-to-end (old unique chunks freed, head intact)
|
2026-06-23 01:01:54 -05:00 |
|
|
|
55175fa2ac
|
feat(M2): hub server + transport client + push engine + CLI 🛰️
- internal/hub: HTTP server (join/publish/have/blob/push/head/metrics), bearer auth,
blob hash-verify, hand-rolled Prometheus /metrics (no dep)
- internal/transport: device HTTP client for the full wire contract
- internal/syncer: device push engine (build manifest -> upload missing blobs ->
commit snapshot) + .devignore loader; in-process e2e test (join->publish->push)
- meta: idempotent AddSnapshot (content-addressed re-push advances head, no double
refcount) + busy_timeout for multi-process CLI access
- cmd/devbox-hub: serve/token/readonly/revoke; cmd/devbox: real join + publish/push
- config: persist bearer + device id
Verified end-to-end with real binaries: secret blocked, node_modules ignored,
re-publish dedups to 0 uploads.
|
2026-06-22 23:40:18 -05:00 |
|