Skip to Content
Alzo

Quickstart

This walkthrough runs a supplied Node.js API on your machine and PostgreSQL in Docker, edits the API, then stops and removes everything. It uses allocated loopback URLs, so it needs no domain, certificate installation or account.

1. Build and install

You need macOS or Linux, Node.js 24.16+ or 26.1+ (not 25), pnpm 10.19.0, npm and a running local Docker Engine 25+. The CLI checks Docker even for a graph of host processes. Installation lists the requirements in full.

In the Alzo checkout:

pnpm install --frozen-lockfile
pnpm package:cli -- --version 0.0.0-local.1

In a separate parent directory, copy the supplied example and install the packages into it. Replace /path/to/alzo below with the absolute path of the checkout. The example contains package.json, alzo.config.ts and app/server.mjs.

cp -R /path/to/alzo/examples/local-development ./alzo-demo
cd alzo-demo
npm install --save-dev \
  /path/to/alzo/.artifacts/packages/0.0.0-local.1/alzo-0.0.0-local.1.tgz \
  /path/to/alzo/.artifacts/packages/0.0.0-local.1/alzo-otel-node-0.0.0-local.1.tgz
npx --no-install alzo --version

Both tarballs must have the same version. npx --no-install runs the installed executable; installing locally does not put a bare alzo command on your shell's PATH.

2. Check, inspect, start

From alzo-demo:

npm run check
npx --no-install alzo doctor
npx --no-install alzo plan
npm run dev

check validates types and graph shape without starting anything. doctor checks Docker, the workspace and ports; its certificate and DNS rows say not required for this configuration. plan lists the intended actions and readiness policies, not live URLs.

Wait for db and api to become ready, and keep this terminal open. Alzo prints the API and dashboard URLs; open those exact addresses in your browser. The API returns Hello from Alzo. In the dashboard, select api for its logs and resolved environment, or open the Graph view to see its database dependency.

The API is deliberately dependency-free: its environment contains a database URL, but its HTTP handler does not query PostgreSQL. The next commands prove SQL access separately. In a second terminal, enter the same project directory:

npx --no-install alzo status --json
npx --no-install alzo exec db -- psql -U postgres -d acme -c "SELECT current_database();"
npx --no-install alzo exec api -- pwd
npx --no-install alzo logs api --tail 20

The SQL result is acme, and pwd ends in /app. If you missed the startup output, read the API's url and the dashboard field from status. Do not copy a port number from an example: allocation depends on the machine and the worktree.

3. Make an edit

Change Hello from Alzo in app/server.mjs, save, then refresh the API page. Node's --watch restarts the application. There is no Alzo watch setting to add for an application that already watches its own files.

Changing alzo.config.ts is different. It marks the dashboard and terminal as config changed without changing running processes. Apply a configuration edit with:

npx --no-install alzo check
npx --no-install alzo reload

Reload validates the new configuration and then replaces the complete graph; it is not a source-code reload mechanism. An invalid configuration leaves the old graph running, and an accepted one can still fail during startup. The edit-loop table lists what to do for each kind of change.

4. Stop, resume, remove

Press Ctrl-C in the terminal running npm run dev. The processes stop; the database volume stays. To resume with background supervision and return once everything is ready:

npx --no-install alzo up --wait
npx --no-install alzo status
npx --no-install alzo stop

After a stop with no targets, resume with up; start api needs an environment that is still running. To remove this instance's containers and networks:

npx --no-install alzo down

This example explicitly retains its database volume, and the removal output names it. To dispose of the data as well, follow reset retained database data to inspect and remove that exact volume. Do not remove unrelated Docker data. Alzo also keeps allocation and log history under ~/.alzo; those files are not running workloads, and you need not delete them to run again.

Continue with Everyday development for worktrees, debugging and troubleshooting, or Configuration basics to write a configuration of your own.

On this page