Skip to content

Feat/slim updates - #254

Merged
robdmac merged 3 commits into
mainfrom
feat/slim-updates
Jul 9, 2026
Merged

robdmac merged 3 commits into
mainfrom
feat/slim-updates

Conversation

@robdmac

@robdmac robdmac commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

No description provided.

robdmac and others added 3 commits July 9, 2026 08:17
…dle it

The 3GB sandbox disk image dominated every auto-update (~1GB compressed). Stop
bundling it in the .app so the updater artifact drops to ~tens of MB; download
it once per image version and verify against a SHA-256 baked into the notarized
binary.

- tauri.conf: drop resources/vm/sandbox.img from the bundle.
- vm/image.rs: ensure_vm_image() resolves the image by (1) local dev/bundled
  resource, (2) cached data-dir image for the current version, (3) migration —
  adopt an image a prior install already staged (0 download), or (4) download
  the gz artifact, verify SHA-256, decompress. Progress is reported via callback.
- vm-image.json: committed manifest (version + gz sha256 + url) embedded at build
  time; updated by the new publish-vm-image.sh, which gzips + uploads the image
  to a dedicated `vm-image-<ver>` release tag.
- Existing v0.2.x installs adopt their already-staged image, so updating costs
  ~0 extra bytes; only fresh installs (or a genuine image change) download.

NOTE: vm-image.json ships a PLACEHOLDER hash — a release that serves fresh
installs must run publish-vm-image.sh first to publish the image + fill the hash.

REVISION: vm-image-on-demand-v1

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_014t8Ukp4NPWtqJ55X261wMZ
P1: only adopt a marker-less staged image when the required version is still the
legacy (v1) image; on a future v2+ a marker-less image is the OLD one and is now
re-downloaded instead of being silently stamped as current.

P2: decompress the verified download to sandbox.img.part and atomically rename
into place, so a crash / disk-full mid-decompress can't leave a partial
sandbox.img that a later launch would adopt as complete.

P3: revision markers — bump main.rs to main-v11-vm-image-ondemand; add markers to
vm/image.rs and vm/error.rs.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_014t8Ukp4NPWtqJ55X261wMZ
@robdmac
robdmac merged commit d5021c9 into main Jul 9, 2026
1 check passed
@robdmac
robdmac deleted the feat/slim-updates branch July 9, 2026 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant