Documentation
Building from Source

Building from Source

How to build LocalDomain for production on each platform.

Build the Daemon

The daemon must be built separately. It runs as a privileged system service.

cargo build -p localdomain-daemon --release

Build the App

macOS (signed DMG)

APPLE_ID="[email protected]" \
APPLE_PASSWORD="app-specific-password" \
APPLE_TEAM_ID="YOUR_TEAM_ID" \
npx tauri build --bundles dmg

Output: target/release/bundle/dmg/LocalDomain_x.x.x_aarch64.dmg

Windows (MSI + NSIS)

npx tauri build

Output: target/release/bundle/msi/ and target/release/bundle/nsis/

Linux (DEB)

npx tauri build --bundles deb

Output: target/release/bundle/deb/

Install the Daemon

After building, the daemon needs to be installed as a system service.

macOS

sudo cp target/release/localdomain-daemon /usr/local/bin/localdomain-daemon
./scripts/install-daemon.sh

Windows (Administrator PowerShell)

.\scripts\install-daemon.ps1

Linux

sudo cp target/release/localdomain-daemon /usr/local/bin/localdomain-daemon
sudo cp resources/localdomain-daemon.service /etc/systemd/system/
sudo systemctl daemon-reload && sudo systemctl enable --now localdomain-daemon

Download Caddy

The daemon needs a Caddy binary. Use the provided scripts:

PlatformScript
macOS./scripts/download-caddy.sh
Windows.\scripts\download-caddy.ps1
Linux./scripts/download-caddy-linux.sh

File Locations

ResourcemacOS / LinuxWindows
Data root/var/lib/localdomain/C:\ProgramData\LocalDomain\
Certificates/var/lib/localdomain/certs/C:\ProgramData\LocalDomain\certs\
Caddy config/var/lib/localdomain/caddy/C:\ProgramData\LocalDomain\caddy\
Caddy binary/usr/local/bin/caddyC:\ProgramData\LocalDomain\bin\caddy.exe
Daemon binary/usr/local/bin/localdomain-daemonC:\ProgramData\LocalDomain\bin\localdomain-daemon.exe
Database~/.local/share/com.localdomain.app/localdomain.db%APPDATA%\com.localdomain.app\localdomain.db