# Optional legacy/test bootstrap token. New deployments add a personal GitHub # Copilot provider through Admin Console or the management API. GITHUB_TOKEN=ghp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx # Optional legacy/test bootstrap keys for shared providers AZURE_FW_GLM5_KEY=your-azure-fw-glm5-key AZURE_KIMI_K25_KEY=your-azure-kimi-k25-key AZURE_OAI_KEY=your-azure-openai-key # Anthropic API key (direct API access for Claude models) # ANTHROPIC_API_KEY=your-anthropic-api-key # Provider types/models are declared by model_providers.json. Runtime providers # and ordinary/system defaults are managed through Admin or management APIs. # Duroxide PostgreSQL store (local Docker) DATABASE_URL=postgresql://postgres:postgres@localhost:5432/durable_copilot # Canonical storage provider configuration. Defaults shown; leave commented for # the standard local PostgreSQL setup. # PILOTSWARM_RUNTIME_PROVIDER=postgres # PILOTSWARM_RUNTIME_URL=postgresql://postgres:postgres@localhost:5432/durable_copilot # PILOTSWARM_SESSION_CATALOG_URL= # PILOTSWARM_FACTSTORE_URL= # PILOTSWARM_CMS_SCHEMA=copilot_sessions # PILOTSWARM_FACTS_SCHEMA=pilotswarm_facts # PILOTSWARM_DUROXIDE_PROVIDER=postgres # PILOTSWARM_DUROXIDE_URL=postgresql://postgres:postgres@localhost:5432/durable_copilot # PILOTSWARM_DUROXIDE_SCHEMA=ps_duroxide # PILOTSWARM_USE_MANAGED_IDENTITY=false # PILOTSWARM_AAD_DB_USER= # Optional graph/enhanced facts surfaces for providers such as horizondb. # PILOTSWARM_GRAPH_ENABLED=0 # PILOTSWARM_GRAPH_URL= # PILOTSWARM_GRAPH_SCHEMA=horizon_graph # PILOTSWARM_GRAPH_REGISTRY_SCHEMA=horizon_graph_registry # PILOTSWARM_GRAPH_NAMESPACE_CACHE_TTL_MS=60000 # PILOTSWARM_EMBED_URL= # PILOTSWARM_EMBED_MODEL= # PILOTSWARM_EMBED_DIM= # PILOTSWARM_EMBED_API_KEY= # PILOTSWARM_EMBED_API_KEY_HEADER= # PILOTSWARM_EMBED_BEARER= # Optional PostgreSQL / runtime scaling knobs (env-only configuration) # DUROXIDE_PG_POOL_MAX=10 # PILOTSWARM_CMS_PG_POOL_MAX=3 # PILOTSWARM_FACTS_PG_POOL_MAX=3 # PILOTSWARM_ORCHESTRATION_CONCURRENCY=2 # PILOTSWARM_WORKER_CONCURRENCY=2 # PILOTSWARM_TURN_TIMEOUT_MS=1200000 # Stop a pooled Copilot runtime after this many idle ms; 0 keeps idle runtimes. # PILOTSWARM_COPILOT_CLIENT_IDLE_STOP_MS=30000 # Duroxide lock settings; an unset renewal buffer is 75% of its lock timeout. # PILOTSWARM_WORKER_LOCK_TIMEOUT_MS=10000 # PILOTSWARM_WORKER_LOCK_RENEWAL_BUFFER_MS= # PILOTSWARM_ORCHESTRATOR_LOCK_TIMEOUT_MS=60000 # PILOTSWARM_ORCHESTRATOR_LOCK_RENEWAL_BUFFER_MS=45000 # PILOTSWARM_SESSION_LOCK_TIMEOUT_MS= # PILOTSWARM_SESSION_LOCK_RENEWAL_BUFFER_MS= # Publish coalesced in-progress assistant text/reasoning to the portal (default off). # PILOTSWARM_LIVE_TURN=1 # ── Optional provider overlays ────────────────────────────────────────────── # The default facts provider is plain Postgres (PgFactStore) and is configured # only by DATABASE_URL / *_FACTS_* settings above. Keep HorizonDB provider # settings out of root .env so `./scripts/run-tests.sh` exercises the baseline # provider by default. # # Copy `.env.horizondb.example` to `.env.horizondb` for HorizonDB coverage: # ./scripts/run-tests.sh --all-providers # baseline + additive HDB coverage # ./scripts/run-tests.sh --with-horizondb # entire suite on HDB # Azure Blob Storage for session dehydration/hydration # Disabled for local runs so PilotSwarm uses filesystem session/artifact stores. # Re-enable or use .env.remote for blob-backed remote runs. # AZURE_STORAGE_CONNECTION_STRING= # AZURE_STORAGE_CONTAINER=copilot-sessions # Entra ID auth for the web portal (optional — omit to disable auth) # Register an app in Azure AD / Entra ID and add the portal URL as a SPA redirect URI. PORTAL_AUTH_PROVIDER=entra PORTAL_AUTH_ENTRA_TENANT_ID= PORTAL_AUTH_ENTRA_CLIENT_ID= # Identity-aware reverse-proxy auth (optional alternative to Entra). # Signed assertion mode (recommended): # PORTAL_AUTH_PROVIDER=proxy # PORTAL_AUTH_PROXY_MODE=jwt # PORTAL_AUTH_PROXY_JWKS_URL=https://access.example.com/cdn-cgi/access/certs # PORTAL_AUTH_PROXY_ISSUER=https://access.example.com # PORTAL_AUTH_PROXY_AUDIENCE= # PORTAL_AUTH_PROXY_JWT_HEADER=cf-access-jwt-assertion # Unsigned header mode is safe only when the portal origin is unreachable # except through the proxy; startup requires the explicit acknowledgement. # PORTAL_AUTH_PROXY_MODE=header # PORTAL_AUTH_PROXY_TRUST_HEADERS=true # PORTAL_AUTH_PROXY_SUBJECT_HEADER=x-forwarded-user # PORTAL_AUTH_PROXY_EMAIL_HEADER=x-forwarded-email # PORTAL_AUTH_PROXY_NAME_HEADER=x-forwarded-preferred-username # PORTAL_AUTH_PROXY_GROUPS_HEADER=x-forwarded-groups # Optional portal authz email allowlists. # Use normalized user email addresses. # If omitted, any successfully authenticated user is allowed in. # PORTAL_AUTHZ_ADMIN_GROUPS=admin1@contoso.com,admin2@contoso.com # PORTAL_AUTHZ_USER_GROUPS=user1@contoso.com,user2@contoso.com # ── Ownership / visibility security model ────────────────────────────── # Per-user session access (docs/proposals/user-admin-security-model.md). # Dark-launch by default: classification + audit run, nothing is blocked. # Flip to true to enforce (users see/act only on their own + shared sessions; # admins keep fleet-wide access). session:share and fleet:admin are always # enforced regardless of this flag. # AUTHZ_ENFORCE_OWNERSHIP=false # Operator policy: unrestricted (default) | cluster. Cluster requires auth and # ownership enforcement; admin system-session read/write access is retained. # AUTHZ_ADMIN_SCOPE=unrestricted # Default visibility for newly created sessions: private | shared_read | shared_write. # Existing sessions are migrated as private; changing this value does not alter # them. Before enabling enforcement on an existing shared stamp, explicitly # share/update the sessions that should remain collaborative, or keep enforcement # false during the transition. # SESSIONS_DEFAULT_VISIBILITY=private # System-session visibility to non-admin users: read (metadata-visible) | admin (hidden). # SESSIONS_SYSTEM_VISIBILITY=read # ── Dev auth provider (LOCAL TESTING ONLY — never production) ─────────── # Authenticates as one of a fixed roster of personas with no IdP; token is the # literal string "dev:". Fail-closed: only an explicit # PORTAL_AUTH_PROVIDER=dev selects it, it refuses to start without # PORTAL_AUTH_DEV_ALLOW=true, and it refuses to coexist with any PORTAL_AUTH_ENTRA_*. # PORTAL_AUTH_PROVIDER=dev # PORTAL_AUTH_DEV_ALLOW=true # Optional roster override (default: ada:admin, alice:user, bob:user, carol:user, dave:user): # PORTAL_AUTH_DEV_USERS=ada:admin,alice:user,bob:user,carol:user,dave:user