Sprint 10 in progress: desktop packaging (A2)

Sprint 10 is still open. This is a mid-sprint build-in-public checkpoint, not a closure post.

A1 made the sidecar runnable under plain Node and env-driven for the MCP entry. A2 ships the runtime itself: a pinned Node binary as a Tauri externalBin, plus esbuild bundles of the sidecar and product MCP server so a packaged app does not need the monorepo node_modules tree.

Context: ADR-0010 Option A · Sprint 10 worklog · commit a466c57.


What A2 delivered

  • Pinned Node 22.17.0apps/desktop/scripts/fetch-node-runtime.mjs downloads the official Node binary per Rust target triple and writes src-tauri/binaries/meronq-node-<triple>[.exe]. Not SEA/pkg (ADR-0010 skips Option B).
  • Tauri externalBinbundle.externalBin: ["binaries/meronq-node"] plus shell allow-spawn/execute capabilities so the host can run that sidecar later (A3).
  • esbuild runtime JSbuild:runtime emits src-tauri/resources/runtime/sidecar.mjs and mcp-server.mjs (workspace packages inlined; node:* builtins including node:sqlite stay external).
  • prepare:packagedtauri:build’s beforeBuildCommand runs fetch + runtime bundles + UI. Binaries and generated JS are gitignored; regenerate locally or in CI.

Smoke on Windows: bundled meronq-node reports v22.17.0 and serves sidecar /health from the esbuild output.


Why this matters

A1 removed monorepo-path assumptions. A2 removes the assumption that the end user has Node ≥22.5 on PATH. The installer can carry its own runtime; A3 can spawn it from Rust with resource paths and MERONQ_MCP_SERVER_ENTRY.

tauri:build
  prepare:packaged
    fetch:node     → binaries/meronq-node-<triple>
    build:runtime  → resources/runtime/{sidecar,mcp-server}.mjs
    build:ui       → Vite dist

packaged app (A3+)
  Rust → meronq-node sidecar.mjs
       → MERONQ_MCP_SERVER_ENTRY=…/mcp-server.mjs

Next in Sprint 10

Task Focus
A3 Launch + supervise the sidecar from Rust
A4 Restart-on-hang watchdog (known write/sync wedge)
A5 tauri build verify on Windows and macOS
A6 Docs + optional CI matrix

Full recap when Sprint 10 closes.


Follow along

← Back to blog