feat(desktop): native macOS app packaged as Apple Silicon DMG - #26
Merged
Conversation
An Electron shell that boots the full Campfire server as a bundled Bun sidecar (backend + minimal node_modules + Bun runtime staged into the app bundle), so every backend and feature ships identically to the web build with no Bun install required. - Reuse-first boot: attaches to an existing Campfire on :4567 (service installs, bunx) instead of double-spawning against ~/.campfire; otherwise spawns on the first free port - afterPack hook copies backend node_modules (electron-builder drops them from extraResources by default) and ad-hoc signs the bundle (valid signature on Apple Silicon, no Apple Developer account needed) - Orchestration MCP server now spawns via the running Bun executable's absolute path so multi-agent tools work without a global bun install - CI: macos-14 job builds the DMG on v* tags and attaches it to the GitHub Release; desktop helper tests wired into ci.yml - make desktop-stage / desktop / dmg targets; docs in desktop/README.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
desktop/, distributed as a DMG attached to GitHub Releases.node_modules(hono, croner, @lancedb/lancedb), and the Bun runtime ship inside the .app — then loads the web UI in a native window. Every feature is included by construction.Why
Behavior
bunx the-campfire) instead of double-spawning against~/.campfire; otherwise spawns the sidecar on the first free port.~/.campfirestate with the CLI/web flavors; sidecar logs at~/.campfire/logs/desktop-server.log; Cmd+Q stops the sidecar, agent processes resume on next launch like any server restart.Notable fixes found along the way
node_modulesfromextraResources; the bundle appeared to work because Bun auto-installs missing packages at runtime (would break offline). The afterPack hook now copies them explicitly.codesignrejectsnode_modules/.binsymlinks — stripped during packaging.bunPATH lookup; it now uses the running Bun executable's absolute path, so multi-agent tools work in the desktop app and on machines without a global Bun install.Testing
web: typecheck + full suite green (87 files, 1635 tests), including new coverage for the Bun-runtime MCP command branch.desktop: 6 unit tests for the boot helpers (free-port scan, Campfire probe, readiness wait).codesign --verify --deep --strict).