Environment Variables

Full .env reference — secrets, ports, runtime flags, LLM keys, and frontend config.

About

Reference for every environment variable the stack reads from .env. Grouped by purpose: secrets, database credentials, runtime flags, LLM provider keys, email, and frontend build-time config.

cp .env.example .env

The stack boots fine with defaults. Replace CHANGEME secrets before sharing with others.

Required secrets

VariableGenerate withUsed by
SECRET_KEYopenssl rand -hex 32Django sessions, CSRF, password reset
PG_PASSWORDopenssl rand -base64 24PostgreSQL auth
MINIO_ROOT_PASSWORDopenssl rand -base64 24MinIO object storage auth
AGENTCC_INTERNAL_API_KEYopenssl rand -hex 32Backend ↔ gateway shared secret

Database credentials

VariableDefaultNotes
PG_USERfutureagiPostgreSQL username
PG_PASSWORDCHANGEMEMust change
PG_DBfutureagiPostgreSQL database name
MINIO_ROOT_USERfutureagiMinIO username
MINIO_ROOT_PASSWORDCHANGEMEMust change
CH_USE_REPLICATED_ENGINESfalsetrue only for multi-node ClickHouse

Ports

All configurable. See Requirements → Ports reference for the full table with defaults and exposure scope.

Backend runtime

VariableDefaultDescription
ENV_TYPEdevelopmentdevelopment · staging · prod — prod mode disables debug output, enables check --deploy
FAST_STARTUPfalseSkip migrations on restart (dev only). Always false in production.
GRANIAN_WORKERS1ASGI worker processes. Set to CPU count in production.
GRANIAN_THREADS2Threads per worker.
ENABLE_GRPCtrueEnable gRPC endpoint.
ENABLE_HTTPtrueEnable HTTP/REST endpoint.

Temporal worker

VariableDefaultDescription
TEMPORAL_NAMESPACEdefaultTemporal namespace.
TEMPORAL_ALL_QUEUEStrueSingle worker polls all queues. Set false + use dev overlay for per-queue workers.
TEMPORAL_MAX_CONCURRENT_ACTIVITIES50Max concurrent activity tasks.
TEMPORAL_MAX_CONCURRENT_WORKFLOW_TASKS50Max concurrent workflow tasks.

LLM gateway

VariableDefaultDescription
AGENTCC_INTERNAL_API_KEYCHANGEMEMust change. Backend authenticates gateway calls with this.

LLM provider keys

Leave blank for providers you’re not using.

VariableProvider
OPENAI_API_KEYOpenAI
ANTHROPIC_API_KEYAnthropic
GOOGLE_API_KEYGoogle Gemini
AWS_ACCESS_KEY_ID / AWS_SECRET_ACCESS_KEY / AWS_REGIONAWS Bedrock + S3

Email (Mailgun)

Required for email-based sign-up and password reset. Without these, create users via the Django shell — see User Management.

VariableDescription
MAILGUN_API_KEYMailgun private API key
MAILGUN_SENDER_DOMAINVerified Mailgun sending domain
DEFAULT_FROM_EMAILFrom: address for outbound emails
SERVER_EMAILDjango admin error emails

Frontend build-time

Warning

These are baked into the JS bundle at Vite build time. Changing them requires rebuilding: docker compose build frontend

VariableDefaultDescription
VITE_HOST_APIhttp://localhost:8000Backend URL as seen by the browser. In production: your public backend URL.
VITE_ENVIRONMENTdevelopmentFrontend analytics and feature flags.

Optional

VariableDefaultDescription
RECAPTCHA_ENABLEDfalseEnable reCAPTCHA on registration.
RECAPTCHA_SECRET_KEYreCAPTCHA v2/v3 server-side key.
VITE_GOOGLE_SITE_KEYreCAPTCHA client-side key (requires frontend rebuild).
FUTURE_AGI_CLOUD_API_KEYEE-tier Cloud features only. Leave blank for OSS.
FUTURE_AGI_CLOUD_API_URLhttps://api.futureagi.comDo not change.

Next Steps

Was this page helpful?

Questions & Discussion