Skip to main content
Boot-time infrastructure settings live in .env. Credentials can use dedicated files. Runtime settings, including SSO, normally live in the admin UI, while file-backed sensitive settings remain only in process memory.

Required for production

Source deployments must override these before going live. Server-package setup generates the secret values and file references automatically: The server-package installer generates these credentials in an operator-owned secrets/ directory. Directories use mode 0750, files use mode 0640, and OBSERVAL_SECRET_GID grants the containers read access through the operator’s group. Existing deployments can keep direct environment values. With a terminal, setup prompts for the frontend URL, bind address, and observability profile. Without a terminal, the same installer selects http://localhost:3000, loopback binding, and no optional observability stack. It prints the initial super-admin email, generated password, and password-file path after the first successful startup. Existing headless installations preserve their configuration rather than replacing it.

Secret files

For any supported credential named NAME, set NAME_FILE to a UTF-8 file path instead of placing the value in .env:
The reader accepts files up to 64 KiB and removes one trailing newline. Setting both NAME and NAME_FILE is an error, so precedence is never ambiguous. Replace a file atomically and restart the affected API or worker processes to rotate the value without rebuilding Observal. File-backed dynamic settings are marked externally managed in the admin API. Their contents are not imported into PostgreSQL or Redis, and the admin API rejects attempts to overwrite, delete, or revoke them. Supported file-backed boot credentials include DATABASE_URL, CLICKHOUSE_URL, REDIS_URL, SECRET_KEY, OLD_SECRET_KEY, JWT_KEY_PASSWORD, GIT_CLONE_TOKEN, and every DEMO_*_PASSWORD. SSO environment imports support the same form, including OAuth client secrets, Google and GitHub OAuth secrets, the insights provider key, SAML certificates, and the SAML key-encryption password. CLI tokens support OBSERVAL_ACCESS_TOKEN_FILE, OBSERVAL_API_KEY_FILE, and OBSERVAL_TOKEN_FILE. PostgreSQL containers use POSTGRES_PASSWORD_FILE. The server package generates a hashed ClickHouse user configuration instead of putting its database password in .env. Service-specific subdirectories expose only the PostgreSQL password to PostgreSQL, the ClickHouse health credential to ClickHouse, and the Grafana and ClickHouse datasource credentials to Grafana.

SSO-only mode

Set deployment.sso_only=true in Admin → SSO when you want IdP-only access. Leave it false to keep password login available.

Demo accounts

Seeded on first startup only when no users exist:
Remove demo account variables and their password files before a real deployment. Existing demo users survive after removal. Delete them manually (observal admin delete-user <email>).
Admin settings warning: If demo accounts are still active or SECRET_KEY is insecure, the admin Settings page will display a warning banner at the top so operators can spot and fix the issue without digging through logs.

Database connections

Source deployments may use direct values:
Server-package installs use file references instead:
Inside Docker Compose, hostnames resolve via the observal-net bridge (e.g. observal-db). Outside Docker (e.g. CLI running on host against dockerized DBs), use localhost:<port>.

OAuth / SSO

Optional. Configure OIDC, SAML, and SSO-only mode in Admin → SSO. OIDC client changes are stored immediately, then take effect after the API restarts. Full setup in Authentication and SSO.

Rate limiting

Tighten for higher-traffic deployments.

ClickHouse retention

Session events older than this are removed from ClickHouse. Set to 0 to disable retention. The minimum non-zero value enforced on startup is 7.

JWT keys

The server generates asymmetric keys on first boot and stores them in $JWT_KEY_DIR. Back up this directory: losing the keys invalidates every session. Changing JWT_SIGNING_ALGORITHM and restarting retires the current public key, generates the selected key type, and keeps old tokens verifiable during their normal lifetime. SAML service-provider material can be mounted independently:
Set both files together. They override database-generated SP material, are reported as externally managed, and cannot be regenerated or removed through the admin API. Replace both files and restart the API to rotate them. More: Authentication and SSO.

Git operations (submission analysis)

GIT_CLONE_TOKEN_HOSTS is required for authenticated clones: without it the token is never sent. List exact hostnames separated by commas (for example github.com,gitlab.example.com, or git.example.com:8443 for a nonstandard port); subdomains and lookalikes are not trusted automatically. Authorities match exactly: github.com:443 requires its own entry and does not match github.com. Only HTTPS clones receive credentials, even if HTTP clones are enabled. GIT_CLONE_TOKEN_USER varies by provider: x-access-token for GitHub, oauth2 or private-token for GitLab.

Observal CLI (client-side) env vars

Not set in .env on the server. These live on the CLI user’s machine. Full list: Environment variables.

Next

→ Ports and volumes