Skip to content

Desktop Builds

The desktop app wraps the same frontend in Tauri 1. The Rust side lives in src-tauri/.

Prerequisites

In addition to the Local Setup prerequisites:

  • Rust, through rustup
  • On Linux, the WebKitGTK development packages, e.g. on Debian or Ubuntu:
sudo apt-get install libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev

See Tauri's prerequisites for other platforms.

  • MkDocs, to build the documentation the app bundles:
pip install -r docs-requirements.txt

Running in Development

pnpm tauri dev

This starts pnpm dev and opens the app in a desktop window, loading the frontend from the dev server, so changes reload as in the browser.

The app reads config.json from src-tauri/ and SQUIRREL_CONFIG, as it would when deployed; see the Configuration Reference. Copy the example to start:

cp config.json.example src-tauri/config.json

Requests then go straight to the instance's apiUrl, not through the dev server's proxy, so the instance needs a key; the API key banner asks for one.

The documentation isn't built in this mode, so Help opens the published documentation site instead.

Building

pnpm tauri build

The build first runs mkdocs build -d src-tauri/docs and pnpm build, then packages the app with them. The result is in src-tauri/target/release/bundle/. CI builds only the RPM:

pnpm tauri build --bundles rpm

If mkdocs isn't installed, the build stops with exit code 127.

What the Rust Side Does

File Purpose
src-tauri/src/site_config.rs The read_site_config command: reads the file named by SQUIRREL_CONFIG
src-tauri/src/docs.rs Serves the bundled documentation over a docs:// URL, and the open_docs command behind Help
src-tauri/tauri.conf.json App identity, the bundled resources (config.json, docs/), the --instance option, and what the frontend may access