/docs/self-host/env

Environment variables

Every obsrv service is configured by environment variables — no config files in containers.

Keep local and production databases separate. Local development should use localhost Postgres or the Docker Compose database. Production should use the managed Postgres/Cloud SQL connection from Secret Manager and must not point at a local connection string.

Go API

VariableRequiredDefaultDescription
PORTNo8080HTTP port
ENVNodevdev or production
DB_URLYesPostgres connection string
GCS_BUCKETYesObject storage bucket name
GCS_ENDPOINTNoOverride for fake-gcs in dev
BQ_PROJECTYesWarehouse project ID
BQ_DATASETNoobsrvWarehouse dataset
BQ_ENDPOINTNoOverride for BQ emulator in dev
JWT_SECRETYesShared with the dashboard
ANTHROPIC_API_KEYNoUsed for cluster auto-labelling
OPENAI_API_KEYNoUsed for embedding generation

Dashboard

VariableRequiredDefaultDescription
NEXT_PUBLIC_API_URLNohttp://localhost:8080Go API URL
NEXTAUTH_URLNohttp://localhost:3100Public dashboard URL
NEXTAUTH_SECRETYesNextAuth session encryption secret
JWT_SECRETYesShared with Go API
DATABASE_URLYesSame Postgres as Go API
AUTH_GOOGLE_IDYesGoogle OAuth client ID
AUTH_GOOGLE_SECRETYesGoogle OAuth client secret

SDKs

VariableRequiredDefaultDescription
THETA_API_KEYYesProject API key
THETA_PROJECTNoOptional project filter; API keys are project-scoped
THETA_BASE_URLNohttps://api.obsrv.techAPI endpoint