Pushleft
Pushleft is a source-available deployment platform for small teams, free to self-host under the Functional Source License. You run pl up in a checkout and get an isolated URL. You write no CI pipeline and provision no infrastructure.
This page shows you how to run the developer stack on your laptop and how to verify a change. Start with the handbook for the architecture in one screen, the infrastructure, how to run it and how we verify work.
Repository layout
pushleft-core: the.pl.yamlmanifest, DNS preset, private-network, observability and typed database contracts.pushleft-api: the Rust control plane on PostgreSQL, with idempotent writes and resumable SSE events.pl: the CLI for plan, deploy, list, logs and teardown, secrets, databases, volumes, buckets and domains, and developer access (pl db connect,pl tunnel,pl exec).pushleft-agent: fail-closed host checks, secure Headscale enrollment, node telemetry reconciliation, and typed PostgreSQL, ClickHouse and Valkey host management.pushleft-mesh: the isolated Headscale coordinator runtime, HTTPS route publication, short-lived Vault-backed enrollment and durable mesh job reconciliation. See coordinator operations.pushleft-agent-gateway: mandatory-mTLS node identity, targeted leases, heartbeat fencing and append-only results (agent gateway).pushleft-telemetry-gateway: telemetry-only mTLS identity, OTLP protobuf validation, node binding, rate limits and loopback collector forwarding.pushleft-scheduler: placement that knows capacity and capability, and expands database intents into pinned typed tasks.pushleft-openprovider/pushleft-cloudflare/pushleft-controller: quoted domain registration, durable provisioning, nameserver delegation and DNS reconciliation of owned records (domain registration).- The React/Vite developer console. It shows deployments, services (with a Shell per service), logs, metrics, errors and data. It also shows image scan findings, domains, mail, AI, team, usage and settings.
pushleft-adminandapps/fleet-admin: the fleet admin API and the operators’ Fleet app (Tauri, macOS and iPad). The app shows nodes, a per-server Terminal, the fleet Map, pipeline, deployments, backups and events.pushleft-ai-proxy,pushleft-mail,pushleft-errors: the AI gateway, customer mail and Sentry-compatible error ingest.
Run the developer stack
Herdr workspace
The shared launcher is ../tmux/bin/herdr-pushleft, like the other local Herdr launchers.
- Run
herdr-pushleftto create or focus its workspace. - Run
herdr-pushleft --no-runto create only the pane layout. PUSHLEFT_ROOTselects another checkout.
The workspace has three tabs:
| Tab | Contents |
|---|---|
| runtime | web (:4174), API (:8080), site (:4720), scheduler and PostgreSQL (:55432) |
| tests | manual test commands and a CLI shell |
| claude | the standard two Claude Code panes |
Port 5173 is left free for other dev servers.
Each pane runs its own entrypoint: dev/web, dev/api, dev/site, dev/scheduler, dev/docker, dev/cli or dev/tests. Press up-arrow and Enter to run that process again.
dev/setup creates a private, ignored .env.herdr with a random local token. It keeps an existing file unchanged. It does not load .env or turn on registrar or Cloudflare credentials.
- Source ingestion uses ignored
.local/herdrstorage. The configured registry origin is metadata only, and no builder runs. - Cloud controllers, mTLS gateways and privileged host agents do not start.
- Existing web and API listeners are reused and not killed. An API that you started yourself can have a different token. Set the browser session token as described below.
Tests do not start automatically. Run dev/tests, then choose dev/test-unit, dev/test-web, dev/test-source, dev/test-all or dev/security. Run integration suites one at a time. The security scans still enforce the runtime-image release gate, and this launcher does not bypass it.
The shared implementation stays in scripts/dev. Its older subcommands still work.
Manual startup
You need Rust 1.88+, Node 20+ and Docker with Compose.
-
Create
.env, start PostgreSQL and run the API:cp .env.example .env # Replace both example token values with the same 32+ character random token. docker compose -f compose.dev.yaml up -d set -a; source .env; set +a cargo run -p pushleft-api -
In a second shell, plan and deploy, then start the console:
set -a; source .env; set +a cargo run -p pushleft-cli --bin pl -- plan cargo run -p pushleft-cli --bin pl -- up npm install npm run dev -- --port 4174 -
Open the dashboard at
http://127.0.0.1:4174. Port 5173 is left free for other dev servers.
To run the local console against the staging API, start it with PUSHLEFT_API_PROXY=https://api.stg.pushleft.dev npm run dev and open https://pushleft.test. The session cookie needs HTTPS, so http://127.0.0.1:4174 cannot sign in. Staging is reachable only on the tailnet (staging runbook).
To show local API data in the browser without a development credential in the bundle, set the token for the current tab and reload:
sessionStorage.setItem('pushleftDevToken', 'your-local-token'); location.reload();
Verify
The complete suite needs local Docker, OpenSSL, Python 3, jq and Caddy (PUSHLEFT_CADDY_BINARY selects a binary). It includes real isolated Headscale enrollment and restart and recovery tests. CI pins Caddy by checksum.
cargo fmt --all -- --check
cargo test --workspace
npm run build
npm run test:e2e
npm run test:agent-gateway
npm run test:scheduler
npm run test:database-agent
npm run test:network-agent
npm run test:mesh-controller
npm run test:mesh
npm run test:telemetry-gateway
npm run test:web
npm run security
# Or run all unit/integration/browser suites together:
npm run test:all
npm run test:pl-up-demo runs the whole pl up journey on real processes (pl up demo).
Further documentation
- Architecture: the architecture and the security invariants.
- Domain registration: domain provider setup and the billing and renewal boundary.
- Managed databases: how the agent runs databases.
- Developer access: database tunnels and container shells.
- Design baseline: the approved interface rules.
- The review plan is at output/pdf/pushleft-product-architecture-plan.pdf.
Target deployment contract
- Openprovider registration with Cloudflare authoritative DNS and proxying.
- One private management tailnet, plus a dedicated Headscale workload tailnet per environment.
- 80/443 as the default public ingress.
- OpenTelemetry collection into ClickHouse with 90-day retention, and cookieless web analytics.
- Agent-managed PostgreSQL, ClickHouse and Valkey operations, and private S3 buckets (object storage).
The handbook gives the current state, and each feature page marks its gaps. Open release work includes payment funding and renewals, analytics-route publication and querying, and database HA. It also includes promotion of pinned runtime images that pass the HIGH/CRITICAL image policy.
Security posture
Network admission applies per environment and host, at both placement and agent leasing.
- It needs fresh gateway, firewall and route verification for the same desired generation and separately hashed policies.
- Gateway health checks verify the expected specification, ownership, bridge and IP. Readiness stays closed until the controllers publish and maintain that evidence.
npm run test:network-agentexercises stale and replaced gateways with real Docker containers.npm run test:linux-firewallandnpm run test:linux-routestest real packets, routing-policy shadow detection, ownership and persistent fences in disposable Linux namespaces. The route test simulates the decrypted mesh link. It does not test real multi-host Tailscale transport.- The GitHub verification workflow runs these and the real XFS quota gate on a Linux runner. The quota gate cannot pass on the local Docker Desktop kernel, which has no XFS quota support.
Local development uses an explicit static bearer token, and the API refuses to start without it. Managed authentication uses other credentials (authentication). People sign in with login codes, passkeys or organization SSO. Automation uses scoped tokens, and agents use short-lived mTLS identities.
Secret values never go in .pl.yaml. A role lists secret names, and pl secrets set stores the values per environment (manifest reference).
License: Functional Source License 1.1, Apache 2.0 future licence (LICENSE).
Related
- Handbook: the one page to start from.
- The .pl.yaml manifest: describe your app.
- Deploying the control plane: run Pushleft on servers.
- Operating Pushleft: alerts, SLOs and recovery.