Skip to Content
Get started

Developer Onboarding

Technical reference. This page is for integrations, advanced configuration, or platform operations. For portal tasks, start with the user guide.

Playground workspace: After completing setup, run make playground-seed to provision sample data for the interactive tutorials.

Prerequisites

ToolVersionCheck
Python3.13+python3 --version
Node.js26.xnode --version
pnpm11.xpnpm --version
uvlatestuv --version
Docker24+docker --version
Docker Composev2docker compose version

Quick Start

1. Clone and install

git clone https://github.com/vdoganAnalytixPower/orqestra.git cd Orqestra make install

Expected output: pnpm installs portal dependencies, uv syncs control-plane and runtime-gateway Python environments.

2. Generate local credentials and start infrastructure

make bootstrap make dev-infra

make bootstrap creates or reuses the private, ignored .tools/local-compose bundle. It is the only source of local database, Redis, object-store, identity, and service-authority credentials; do not copy .env.example or export known defaults. The bundle is reused across restarts and a reset/recovery is required before rotating credentials while persistent volumes exist.

A bundle generated before per-role service-credential signing keys were introduced needs a one-time migration before make dev will start: run scripts/bootstrap-local-compose.sh add-role-signing-keys --root "$PWD" once. It adds the new key files and compose.env entries in place (refusing any other drift) and is a no-op if the bundle is already migrated. A fresh bundle created by make bootstrap already includes the seven keys and needs no migration. A bundle with the dedicated runtime-gateway signing key and the older two-key gateway verifier set is upgraded automatically by make bootstrap or make dev: it reuses the existing load-gate public key and preserves the bundle generation. Other bundle drift still fails closed; a bundle that predates the dedicated runtime-gateway signing key requires an explicit reset.

Expected output: PostgreSQL (5432), PgBouncer (6432), four Redis services (6379-6382), MinIO (9000/9001) containers start on loopback.

3. Initialize the database

make db-upgrade make db-seed

Expected output: Alembic applies the migrations and seed data loads.

Pre-live reset/reseed recovery

Migration 255 adds the required server-owned release-origin row and refuses to run when release_record already contains rows. It does not delete or infer origins. On a disposable local database, reset the Docker volumes before retrying. This is local-only and permanently deletes the local Postgres, Vault, and MinIO volumes; never run it against shared or production data:

printf 'yes\n' | make reset make dev

If you only need infrastructure, use make dev-infra, then rerun make db-upgrade and make db-seed. If the database is not disposable, stop and use the migration’s bounded preflight error to coordinate an explicit data migration; do not bypass the check.

4. Run services

Option A — Docker (all services):

make dev

Option B — Local development (separate terminals):

Generate and load the protected local bundle before starting host-native processes. The bundle supplies the database, Redis, object-store, session, and service-signing values; do not copy .env.example or rely on repository defaults.

make bootstrap eval "$(scripts/bootstrap-local-compose.sh host-env --root "$PWD")" # Terminal 1: control-plane with the optional Estate surface cd services/control-plane && uv run uvicorn orqestra_composition.app:app --reload --app-dir src --port 8000 # Terminal 2: runtime-gateway cd services/runtime-gateway && uv run uvicorn orqestra_runtime_gateway.main:app --reload --app-dir src --port 8001 # Terminal 3: portal cd apps/portal && pnpm dev # Terminal 4: docs cd apps/docs && pnpm dev

The control-plane composition includes the optional Estate overview. To run the core-only control plane without Estate routes, use:

cd services/control-plane && uv run uvicorn orqestra_control_plane.main:app --reload --app-dir src --port 8000

Expected output: Control-plane at http://localhost:8000/docs , runtime-gateway at http://localhost:8001/healthz , portal at http://localhost:3000 , docs at http://localhost:3002 

5. Verify

curl http://localhost:8000/healthz # {"status": "ok"} make check # All quality gates pass

Environment Variables

Run make bootstrap in the repo root. Host-side Make targets source the generated bundle automatically; direct service processes must source .tools/local-compose/compose.env explicitly as shown above. Key variables:

VariableDefaultProfileDescription
ORQESTRA_POSTGRES_DSNgenerated in .tools/local-compose/compose.envdefaultApplication-tier Postgres DSN (routes through PgBouncer transaction-mode multiplexing)
ORQESTRA_POSTGRES_DSN_DIRECTgenerated in .tools/local-compose/compose.envdefaultDirect-Postgres DSN for migrations, WORM-export, seed scripts, CLI audit, and Makefile DB helpers.
ORQESTRA_RUN_MIGRATIONS_IN_LIFESPANunset (resolves to service_env == "local")defaultWhen the resolver returns true, the control-plane lifespan runs alembic upgrade head itself; when false, the lifespan runs a schema-drift check that raises if the live DB is not at the script head. Asymmetric override: =false is honoured in any env; =true is honoured only when service_env="local".
ORQESTRA_REDIS_QUEUE_URLgenerated in .tools/local-compose/compose.envdefaultQueue-role Redis (Celery broker / result backend)
ORQESTRA_REDIS_CACHE_URLgenerated in .tools/local-compose/compose.envdefaultCache-role Redis (asset / release caches)
ORQESTRA_REDIS_COORDINATION_URLgenerated in .tools/local-compose/compose.envdefaultCoordination-role Redis (leases, audit, governor)
ORQESTRA_REDIS_SIGNALS_URLgenerated in .tools/local-compose/compose.envdefaultSignals-role Redis (kill / pause TTL keys)
CONTROL_PLANE_URLhttp://localhost:8000fullPortal API proxy target
RUNTIME_GATEWAY_URLhttp://localhost:8001fullPortal system-health readiness target for runtime-gateway
RETRIEVAL_SERVICE_URLhttp://localhost:8002fullPortal system-health readiness target for retrieval-service
NEXT_PUBLIC_GRAFANA_URLhttp://localhost:3001monitoringBrowser-facing Grafana URL used by the portal Monitoring drilldown link
NEXT_PUBLIC_JAEGER_URLhttp://localhost:16686monitoringBrowser-facing Jaeger URL used by the portal Monitoring trace drilldown link
ORQESTRA_MAX_REQUEST_BYTES10485760 (10 MiB)fullMaximum body size accepted by control-plane and runtime-gateway. Oversize requests get HTTP 413 (RFC 7807 application/problem+json) before any route handler runs. Operators enabling ORQESTRA_PERSIST_FULL_AGENT_TRACE=true must raise this (50 MiB is a reasonable starting point).
ORQESTRA_PORTAL_MAX_REQUEST_BYTES10485760 (10 MiB)fullSame cap on the portal proxy (/api/v1/* route handler). Apply at the portal layer to avoid buffering oversize bodies in the Node runtime. Should match (or be tighter than) ORQESTRA_MAX_REQUEST_BYTES — setting the portal higher just wastes Node memory on a request the backend would 413 anyway.
ORQESTRA_GOVERNANCE_PARTITION_CRON0 0 24 * *defaultCron expression for the monthly partition-manager job that pre-creates next month’s governance_events_YYYY_MM partition. Default fires on the 24th of each month at 00:00 UTC, ≈7 days before month-end. The web tier exposes governance_events_next_partition_exists (Prometheus gauge, 1.0/0.0) and governance_partition_health_last_probe_timestamp (heartbeat) so operators can alert on missed rollovers.
LITELLM_MASTER_KEY—llmLiteLLM admin key (only needed with --profile llm)
OPENAI_API_KEY—full / llmOptional. Enables a LiteLLM-routed model (see Governed Providers).

Docker Compose Profiles

Different profiles activate different services and require different env vars:

  • default (no --profile flag): PostgreSQL 17 with pgvector + PgBouncer (transaction-mode pooler), four typed Redis services (queue / cache / coordination / signals), MinIO. Requires ORQESTRA_POSTGRES_DSN (app traffic via PgBouncer), ORQESTRA_POSTGRES_DSN_DIRECT (admin/migration via direct Postgres), and the four ORQESTRA_REDIS_*_URL variables (defaults point at the bundled compose services).
  • full: All default services plus control-plane, retrieval-service, LiteLLM, runtime-gateway, and portal. Additionally requires CONTROL_PLANE_URL, RUNTIME_GATEWAY_URL, and RETRIEVAL_SERVICE_URL for portal proxying and system-health readiness checks. NEXT_PUBLIC_GRAFANA_URL and NEXT_PUBLIC_JAEGER_URL control Monitoring drilldown links when the monitoring profile is also running. OPENAI_API_KEY is optional and only needed if you want a LiteLLM-routed model (see Governed Providers) to work.
  • auth: Default services plus Keycloak and OpenLDAP. Auth-related env vars apply.
  • llm: Default services plus LiteLLM. Requires LITELLM_MASTER_KEY. OPENAI_API_KEY remains optional.

Project Layout

Orqestra/ apps/portal/ # Next.js operator and consumer portal (pnpm) services/ control-plane/ # FastAPI central API service (uv) runtime-gateway/ # FastAPI execution gateway (uv) packages/contracts/ # Shared type contracts infrastructure/local/ # Docker Compose and local infra config docs/ # Architecture, ADRs, reviews tests/ # Cross-service test suites

Common Workflows

TaskCommand
Install all dependenciesmake install
Start infrastructure onlymake dev-infra
Start everything (Docker)make dev (portal 3000, docs 3002)
Run all quality gatesmake check
Run portal testscd apps/portal && pnpm test
Run control-plane testscd services/control-plane && uv run pytest
Reset databasemake reset (local Docker volumes only), then make dev
See all Make targetsmake help

Troubleshooting

  • Port conflict: Check for existing services on 5432, 6379, 3000, 8000 (lsof -i :<port>).
  • uv not found: Install from https://docs.astral.sh/uv/ 
  • pnpm not found: npm install -g pnpm
  • Docker permission denied: Ensure the Docker daemon is running and your user has access.
  • Database connection refused: Ensure make dev-infra is running and PostgreSQL is healthy (docker compose ps).
  • Portal shows “fetch failed”: Ensure control-plane is running at the URL specified in CONTROL_PLANE_URL.

Further Reading