Deploy

Let the installer hand you a running service

A normal deployment does not involve picking files off the releases page. One script handles platform detection, downloading the full archive, verifying SHA-256, backing up your data, installing the service and checking that it came up.

Recommended

One command to install or upgrade

curl -fsSL https://raw.githubusercontent.com/SuInk/Diana/main/scripts/install.sh | sh

Supports Linux amd64/arm64 and macOS on both Intel and Apple Silicon. On Linux it installs as a systemd --user service and on macOS as a LaunchAgent; where no service manager is available it falls back to a background process.

  1. 1

    Detect the platform

    Picks the right full archive for your OS and CPU, and refuses platforms it does not support.

  2. 2

    Download and verify

    Fetches the release's SHA256SUMS alongside it and only extracts once the checksum matches.

  3. 3

    Back up, then switch

    Backs up the database, WAL/SHM files, frontend, old binary and launch script, keeping any existing config.yaml.

  4. 4

    Start and probe

    Polls /api/health for up to 45 seconds. On Unix a failed upgrade restores the previous set of files.

Installer options

Choose an installation interactively, or pass command-line arguments for unattended installs. Application settings live in config.yaml and the WebUI; no configuration environment variables are required.

Unix / WindowsPurpose
--dir PATH / -InstallDir PATHInstallation directory; defaults to the current user.
--scope user|systemUnix installation scope; system requires sudo.
--version VERSION / -Version VERSIONRelease version; default latest.
--host HOST / -BindHost HOSTListen address written to YAML.
--port PORT / -Port PORTListen port; default 18080.
--config-file PATH / -ConfigFile PATHInitial YAML file for a new installation; existing configuration is preserved.
--no-start / -NoStartInstall without starting.
--yes / -YesSkip interactive choices.
curl -fsSL https://raw.githubusercontent.com/SuInk/Diana/main/scripts/install.sh | sh -s -- --dir "$HOME/Applications/Diana" --port 18081 --yes
& ([scriptblock]::Create((irm https://raw.githubusercontent.com/SuInk/Diana/main/scripts/install.ps1))) -InstallDir "$env:LOCALAPPDATA\Diana" -Port 18081 -Yes

PATH is configured automatically. Existing system installs retain their scope and may still require sudo. Stop the old service and preserve configuration and data before moving to another directory.

Alternative

Install a full release archive by hand

For offline environments or where changes need manual approval, download the full archive matching your platform: the .tar.gz or .zip plus SHA256SUMS from the same release. It includes the backend, prebuilt WebUI and launch scripts, with no separate WebUI deployment or Node.js installation needed. Releases no longer provide standalone binaries; custom deployments can extract the executable and frontend assets from the full package.

# macOS Apple Silicon example
shasum -a 256 diana-macos-arm64.tar.gz
tar -xzf diana-macos-arm64.tar.gz
cd diana-macos-arm64
./run.sh
First migration from an older release

Full archives now use the diana-<os>-<arch> naming scheme. Older consoles that only recognize diana-webui-… archives cannot self-update directly; rerun the one-click installer above or install a full package manually the first time.

Docker

Container deployment

Persistence

Mount /app/data — the only directory you need — or rebuilding the container loses the SQLite database and your credentials. It also holds the runtime log (data/logs/diana.log), the optional config.yaml, plugins, skills, MCP configuration, browser and coding-CLI logins and update backups. On start the container hands it to its runtime user (UID 10001), so a host directory Docker created as root still works. The first start on a new image version backs up the database to data/.diana-updates/backups/ before migrating it (at most 3 within 3 days). A config file already mounted at /app/config.yaml still takes precedence; to move it to data/config.yaml, also delete the DIANA_CONFIG line from an old Compose file. Once an old config's log_path: logs/diana.log is changed to data/logs/diana.log (or removed), the old logs/ mount can be dropped.

The published image means you do not have to clone the repository:

curl -fsSL https://raw.githubusercontent.com/SuInk/Diana/main/scripts/docker.sh | sh

For updates, run in the same deployment directory:

docker compose pull && docker compose up -d

The installer can select the full or slim image and records that choice in the deployment directory's .env. See Update channels for rolling tags and updater boundaries, and Browser dependencies and containers for the browser and CJK-font differences.

To build from the repository instead, or to run a QQ client alongside it (SnowLuma recommended), use compose:

git clone https://github.com/SuInk/Diana.git
cd Diana
docker compose -f docker-compose.yml -f docker-compose.build.yml up -d --build
docker compose logs -f diana

When SnowLuma (or another client) and Diana are separate containers, the reverse WebSocket must use the container service name, for example ws://diana:18080/onebot/v11/ws — writing 127.0.0.1 points the client at its own container.

Development

Build from source

Go 1.26.5
Node.js 22
npm
Git
git clone https://github.com/SuInk/Diana.git
cd Diana
go mod download
cd frontend && npm ci && npm run build && cd ..
mkdir -p dist
go build -trimpath -o dist/diana-webui ./cmd/webui
FRONTEND_DIST=frontend/dist ./dist/diana-webui

First login

Configure models first, then connect a channel

  1. 1

    Sign in

    The administrator credentials are printed once to the terminal on first start and stored in config.yaml. Change the password after signing in.

  2. 2

    Configure models

    Sync the model list first, then set the default model; test chat, vision, intent detection and image generation separately.

  3. 3

    Connect a bot

    Fill in the credentials for each platform on the Bots page. All six can be enabled at once, with conversation context always isolated by bot profile.

  4. 4

    Check the events

    Send a test message and confirm the decision reason, tool results and token counts in the event detail view.