devbox/internal/syncer
shoemoney 4b6a4b97b2 harden(durability): fsync atomic writes before publishing the rename 💽
A power loss between rename and the data hitting disk could leave a truncated/
empty file despite the atomic rename — breaking 'never lose a byte'. Now both
atomic-write paths f.Sync() the temp file before rename and best-effort fsync
the parent dir after (so the rename entry is durable too):
- internal/syncer/pull.go atomicWrite (pulled file content)
- internal/hub/blobstore Disk.Put (stored blobs)
Dir fsync is best-effort (unsupported on Windows). [fanned-out subagent: harden-fsync]
2026-06-23 02:59:26 -05:00
..
deploy_test.go feat(M6.5): devbox deploy — pin a mount to a snapshot (no push) 🚀 2026-06-23 01:17:20 -05:00
fsync_test.go harden(durability): fsync atomic writes before publishing the rename 💽 2026-06-23 02:59:26 -05:00
hooks_integration_test.go feat(M5): lifecycle hooks 🪝 2026-06-23 00:48:16 -05:00
preserve_ignored_test.go fix(dataloss): don't clobber a .devignore'd/guarded local file on pull 🩸🛟 2026-06-23 02:28:51 -05:00
pull.go harden(durability): fsync atomic writes before publishing the rename 💽 2026-06-23 02:59:26 -05:00
pull_test.go feat(M5): lifecycle hooks 🪝 2026-06-23 00:48:16 -05:00
restore_test.go feat(M6): versioning — log, restore, hub gc 🕰️ 2026-06-23 01:01:54 -05:00
safejoin_test.go fix(sec): contain manifest paths + verify blob integrity on download 🛡️🧊 2026-06-23 02:24:32 -05:00
syncer.go feat(M5): lifecycle hooks 🪝 2026-06-23 00:48:16 -05:00
syncer_test.go feat(M5): lifecycle hooks 🪝 2026-06-23 00:48:16 -05:00