Install on Linux
Linux is the reference platform: it runs the server and workers.
Requirements
Section titled “Requirements”Git, Node.js 22+, Docker Engine with the Compose plugin, and openssl (the installer uses it to generate
secrets). See the hardware table.
Install the server
Section titled “Install the server”-
Clone and install dependencies.
Terminal window git clone https://github.com/surr-jc/azhi-flow && cd azhi-flownpm ci -
Run the installer.
Terminal window deploy/install.shIt checks for Docker, Compose and openssl, writes
deploy/.envonce with a random server secret and database password (mode 0600, git-ignored), pulls the PostgreSQL and Temporal images, builds the server image, starts everything, waits until all three containers are healthy, and prints the owner token. Re-running it upgrades in place and keepsdeploy/.env. -
Add model access. Store a provider key and set a model, then re-run the installer.
Terminal window npx azhi secret set anthropic-api-key --value sk-ant-... # or openai-api-key# put AZHI_ANTHROPIC_MODEL (or AZHI_OPENAI_MODEL) in deploy/.envdeploy/install.sh
Add a worker
Section titled “Add a worker”Workers run scripts and harnesses. Run one on this host or on another Linux machine.
-
On the worker host, clone and install (omit dev dependencies if you like; this includes the pinned OpenCode binary).
Terminal window git clone https://github.com/surr-jc/azhi-flow && cd azhi-flownpm ci --omit=dev -
Point it at the server and sign in.
Terminal window export AZHI_URL=http://<server>:7400export AZHI_TEMPORAL_ADDRESS=<server>:7233 # localhost:7233 on the same machinenpx azhi login --url "$AZHI_URL" --token <owner token> -
Start the worker.
Terminal window npx azhi worker start --trust workspace-publishers -
Check the tools OpenCode steps need, then verify.
Terminal window npx azhi setup # git, OpenCode, ripgrep; prints the install command for your distronpx azhi doctor # database, Temporal, interpreter builds, workers online
Script nodes also need uv (Python 3.12) and/or Bun on the worker. Details for ripgrep and token saving are on Workers and OpenCode tools.
Installer options
Section titled “Installer options”All are environment variables.
| Variable | Default | Use |
|---|---|---|
AZHI_PORT | 7400 | API and web run page port |
AZHI_PG_PORT, AZHI_TEMPORAL_PORT | 5432, 7233 | Published ports, for workers and the CLI |
AZHI_TEMPORAL_VERSION | 1.29.1 | Temporal server image tag |
AZHI_NODE_IMAGE | node:22-bookworm-slim | Base image, for example a mirror when Docker Hub rate-limits |
AZHI_SKIP_BUILD | unset | 1 uses an azhi-flow/server image that is already loaded |
AZHI_COMPOSE_PROJECT | azhi | Run a second, isolated stack on one host |
More in the environment variable reference.
Verify
Section titled “Verify”npx azhi doctornpx azhi open # prints a link to Mission Control that signs the browser tab inNext: First run.