Skip to Content
MaestroInstallationEnvironment Variables

Environment Variables

Every environment variable Maestro and the MCP Gateway read at runtime. Set these via maestro.env, mcpGateway.env, or global.env in your values.yaml.

Most of the really important knobs are here: OIDC, the public URL, and the AWS region for Bedrock. Per-provider LLM credentials and per-org integration credentials are not env vars — they live in the database and are managed through the admin UI.

Maestro

Database

Usually set automatically by the chart — see the Helm chart reference.

VariableRequiredDefaultNotes
MAESTRO_DATABASE_URLYesFull PostgreSQL URL. The chart composes this from database.* values
MAESTRO_DB_HOSTSet by chart from database.host
MAESTRO_DB_PORT5432
MAESTRO_DB_NAMEmaestro
MAESTRO_DB_USERmaestro
MAESTRO_DB_PASSWORDSourced from the database secret
MAESTRO_DB_SSLMODErequire

Public URL

VariableRequiredDefaultNotes
MAESTRO_BASE_URLYes in prodFull URL the browser hits (e.g. https://maestro.example.com). Must match your OIDC redirect URI
PORT4200HTTP listen port
SPA_ROOT/app/uiPath to the UI static bundle inside the image

OIDC / authentication

See OIDC setup for a walkthrough.

VariableRequiredDefaultNotes
OIDC_ISSUER_URLYesIssuer URL of your IdP. JWKS is discovered from it
OIDC_AUDIENCEmaestro-uiExpected audience (client ID)
OIDC_JWKS_URLderivedOverride if your IdP’s JWKS lives outside the standard discovery path
OIDC_SUPERADMIN_GROUPmaestro-superadminUsers in this OIDC group are promoted to superadmin
OIDC_SUPERADMIN_EMAILSComma-separated email allowlist. Matched case-insensitively. Use this to bootstrap the first superadmin before you’ve wired groups
OIDC_TRUST_UNVERIFIED_EMAILSfalseTreat all OIDC emails as verified regardless of the email_verified claim. Only set this if you trust your IdP to gate email ownership itself (some Okta setups)

Maestro always requires email_verified: true in the token unless OIDC_TRUST_UNVERIFIED_EMAILS=true.

LLM providers (env var form)

In normal operation you configure LLMs through the superadmin UI; those credentials live in the database. These env vars are only read by CLI provisioning helpers and the gateway’s embedding path.

VariableUsed byNotes
ANTHROPIC_API_KEYCLI provisioning
OPENAI_API_KEYCLI provisioning, gateway embeddings
AWS_REGIONBedrock client defaultWhen Bedrock creds are empty in the DB, the SDK falls back to the pod’s credential chain and uses this region
GCP_PROJECT, GCP_REGIONVertex AI embeddings
GOOGLE_APPLICATION_CREDENTIALSVertex AI embeddings (gateway)Path to GCP service account key file

MCP Gateway integration

VariableRequiredDefaultNotes
MCP_GATEWAY_URLhttp://localhost:8080The chart sets this to the in-cluster service URL
MCP_GATEWAY_API_KEYIf set, sent as X-CardinalHQ-API-Key to the gateway

Default Lakerunner bucket

Used by the Lakerunner provisioner when auto-configuring a new org’s bucket. All four must be set together or all omitted.

VariableNotes
DEFAULT_BUCKET_NAME
DEFAULT_BUCKET_CLOUD_PROVIDERaws, gcp, azure
DEFAULT_BUCKET_REGION
DEFAULT_BUCKET_COLLECTOR_NAME

Ontology / repos

VariableDefaultNotes
ONTOLOGY_WORKSPACE_DIR/tmp/ontology-workspacesWritable path for cloned repos. The default sits on the tmp emptyDir — fine for most installs
GITHUB_PATUsed by the ontology CLI, not at runtime

Observability

VariableDefaultNotes
OTEL_SERVICE_NAMEmaestro
OTEL_TRACING_ENABLEDtrue if endpoint setSet to false to disable
OTEL_EXPORTER_OTLP_ENDPOINThttp://localhost:4318HTTP OTLP endpoint
OTEL_EXPORTER_OTLP_HEADERSKey=value,Key2=value2

Misc

VariableDefaultNotes
DEBUGfalseEnables /api/debug/tools. Do not set in prod

MCP Gateway

The gateway runs alongside Maestro and inherits most of its env from global.env. Unique vars:

VariableDefaultNotes
MCP_HOST0.0.0.0
MCP_PORT8080Chart sets this from mcpGateway.port
MCP_DEBUG_PORT9090Chart sets this from mcpGateway.debugPort
MCP_API_KEYIf set, requests must carry X-CardinalHQ-API-Key
MCP_TRANSPORTstdioChart runs the gateway in HTTP mode; set to http if you ever override the entrypoint
MAESTRO_DATABASE_URLSame connection string as Maestro — required for per-org routing
DOCSTORE_DB_PATHauto-discoveredPath to docstore.db
WORKING_DIRECTORYcwdUsed for the embeddings cache
OTEL_SERVICE_NAMEmcp-gateway

Where to set what

ScopeUse
Public URL, OIDC, Postmark, superadmin emailmaestro.env
Bedrock region, OTel endpoint, trace headersglobal.env (both workloads need them)
MCP gateway specifics (API key in-container, docstore path)mcpGateway.env or set on the chart-level field (mcpGateway.apiKey)

Reach out to support@cardinalhq.io for support or to ask questions not answered in our documentation.

Last updated on