Skip to main content

Run the project (Ubuntu)

Ubuntu 22.04 LTS or newer is the supported and tested target. Track 1 (Docker Compose) is the recommended path; Track 2 (bare metal) is at the bottom for advanced setups.

Prerequisites

  • Docker Engine 20.10+ and the docker compose v2 plugin
  • git
If you do not yet have Docker installed, the steps below match the official Docker docs and INSTALL.md:
Verify:
Use docker compose (with a space). The legacy hyphenated docker-compose is the deprecated Python script — install the v2 plugin (docker-compose-plugin package) instead.

Three-step quickstart

The first run pulls images and builds the node container, which can take a few minutes. Subsequent starts are near-instant. When the stack is healthy:
  • Node RPC: http://localhost:53550 — try curl http://localhost:53550/info
  • Grafana: http://localhost:3000 (default admin / demos)
  • Prometheus: http://localhost:9091

Tour of .env

.env.example is the canonical template. The defaults work for local development. The variables you are most likely to touch: Leave PG_HOST=postgres and TLSNOTARY_HOST=tlsnotary exactly as shipped — those are the in-network service names used by docker compose.
Old docs referenced RPC_FEE=5 and SERVER_PORT. Both are wrong. The current names are RPC_FEE (default 1, plus NETWORK_FEE=1 and BURN_FEE=1) and RPC_PORT.

Compose profiles

COMPOSE_PROFILES in .env controls the optional services:

Common operations

State persists in named Docker volumes prefixed demos_ (e.g. demos_node_state holds .demos_identity, demos_pgdata holds chain data). They survive docker compose down but not docker compose down -v.

Going public (VPS / public Ubuntu host)

Before joining a real Demos network:
  1. Set EXPOSED_URL in .env to your reachable address — public IP or DNS — not localhost.
  2. Open the firewall before advertising the public URL:
  3. Do not expose 5432 (Postgres), 9090 (node metrics), 9091 (Prometheus), or 3000 (Grafana) to the public internet.
  4. Seed demos_peerlist.json with bootstrap peers from the team. Do not invent hostnames; use the values the team publishes.
See INSTALL.md for the full peerlist seeding procedure.

Troubleshooting


Track 2: Bare metal with ./run (advanced)

Track 2 runs the node binary natively via Bun and uses Docker only for a Postgres sidecar managed by the ./run script. Pick this path for core development, kernel-level debugging, or TUI-driven operation. The full walkthrough — prerequisites (build-essential, Bun via Mise or the direct installer, Rust for wstcp), ./scripts/install-deps.sh, identity generation, ./run flags — lives in the source of truth: For the bare-metal path, override these in your .env:
  • PG_HOST=localhost
  • PG_PORT=5332
  • TLSNOTARY_HOST=localhost