Skip to content

Server environment variables (full)

All variables are read at boot from the process environment. Most string booleans accept 1 | true | yes (case-insensitive for true/yes) as truthy; other values are falsy. A few flags use their own rule (e.g. SUPACLOUD_SMTP_USE_TLS is on unless set to 0|false|no). The abbreviated admin page covers deployment essentials — see Environment variables (admin).

Variable Default Notes
MODE dev dev relaxes prod-only guards (weaker JWT, no encryption-key requirement). Set to any other value — or omit — for production.
SERVER_HOST 0.0.0.0 Bind address.
SERVER_PORT 8080 Listen port.
PUBLIC_URL http://localhost:<port> in dev, required in prod Canonical public origin. Seeds the CORS allowlist and callback URL derivation.
CORS_ALLOWED_ORIGINS — Comma-separated origins permitted to call the API. When empty, the allowlist defaults to PUBLIC_URL (plus the standard localhost dev origins in dev mode).
RUST_LOG warn,supacloud_server=debug,tower_http=info,vaultrs=off,rustify=off Log filter (tracing env-filter syntax). A set value is laid over vaultrs=off,rustify=off, so RUST_LOG=info does not bring the vault library’s error triplets back.
SUPACLOUD_LOG_FORMAT text json writes one JSON object per line (level, target, message, event and span fields at the top level).
NO_COLOR — NO_COLOR=1 disables ANSI colour in the text log output. Colour is also off whenever stdout is not a terminal, so a container log is never coloured.
Variable Default Notes
DATABASE_URL postgresql://supacloud:supacloud@postgres:5432/supacloud libpq connection string. Can also come from the OpenBao supacloud/db path when SECRET_BACKEND=openbao.
Variable Default Notes
AUTH_PROVIDER builtin One of builtin, oidc, authelia_proxy, oidc_proxy.
SUPACLOUD_JWT_SECRET dev default Session-signing secret. ≥ 32 bytes required. The dev default is rejected for any non-loopback PUBLIC_URL. Also accepted as AUTH_JWT_SECRET (legacy).
SUPACLOUD_INITIAL_ADMIN_EMAILS — Comma-separated emails provisioned as workspace owner on first boot. Required in prod for builtin and oidc providers. Also accepted as SUPACLOUD_INITIAL_ADMIN_EMAIL.
AUTH_SESSION_TTL_MINUTES 480 Session lifetime (8 h).
AUTH_COOKIE_SECURE true in prod, false in dev Set false for local HTTP.
OIDC_ISSUER_URL — OIDC provider discovery URL (AUTH_PROVIDER=oidc).
OIDC_CLIENT_ID — OIDC client ID.
OIDC_CLIENT_SECRET — OIDC client secret. Vault-hydrated from supacloud/app.
OIDC_REDIRECT_URL — OIDC callback URL (/api/auth/oidc/callback).
OIDC_SCOPES openid email profile Space- or comma-separated. Must include openid.
OIDC_PKCE_ENABLED true Set false only for legacy providers that reject code_verifier.
OIDC_TOKEN_AUTH_METHOD basic basic or post (client_secret_post).
AUTH_PROXY_USER_HEADER Remote-User Trusted-proxy user header (authelia_proxy / oidc_proxy).
AUTH_PROXY_EMAIL_HEADER Remote-Email Trusted-proxy email header.
AUTH_PROXY_NAME_HEADER Remote-Name Trusted-proxy display-name header.
AUTH_PROXY_REQUIRED_HEADER — Required for proxy modes. Header name that must be present.
AUTH_PROXY_REQUIRED_VALUE — Required for proxy modes. Expected value of the required header.
AUTH_PROXY_LOGOUT_URL — Upstream proxy sign-out URL surfaced in /config. Only meaningful in proxy-auth modes.
SUPACLOUD_SSO_AUTOREDIRECT derived on forces the single-IdP standalone redirect; off suppresses it. Derived from edition + SSO-realm-count when unset.
DEFAULT_SSO_ORG — Bare org slug pinned as the standalone SSO redirect target.
Variable Default Notes
SECRET_BACKEND auto openbao or env. Auto-detects openbao when vault auth is present; otherwise env. A typo is a hard boot error.
OPENBAO_ADDR https://vault.blockworx.tech OpenBao / Vault address. Also accepted as VAULT_ADDR.
VAULT_TOKEN — Direct token auth.
OPENBAO_ROLE_ID — AppRole role ID (used with OPENBAO_SECRET_ID).
OPENBAO_SECRET_ID — AppRole secret ID.

With SECRET_BACKEND=openbao the following are read from the supacloud/app KV2 map (env wins; vault fills gaps): SUPACLOUD_JWT_SECRET, SUPACLOUD_CREDENTIAL_ENCRYPTION_KEY, OIDC_CLIENT_SECRET, SUPACLOUD_MCP_CONFIRMATION_SECRET, DISCORD_BOT_TOKEN, SUPACLOUD_{LINEAR,NOTION}_OAUTH_CLIENT_{ID,SECRET}, STRIPE_SECRET_KEY, STRIPE_WEBHOOK_SECRET, SUPACLOUD_SMTP_PASSWORD, BW_FINTS_WORKER_API_KEY, SUPACLOUD_OPERATOR_TOKEN, SUPACLOUD_EDITION_LICENSE, SUPACLOUD_EDITION_SECRET.

Variable Default Notes
SUPACLOUD_CREDENTIAL_ENCRYPTION_KEY — AES-256 key for DB-resident credential material. Accepts raw 32 bytes, hex, base64, or hex:/base64: prefix. Required in prod. When vault-sourced, the decoded key is held in-process and never re-exported to the environment.
SUPACLOUD_MCP_CONFIRMATION_SECRET — HMAC secret for deploy-tier MCP confirmation tokens (app.deploy, app.undeploy, app.pause, app.resume, app.migration.apply). The token binds the confirmed call to its inputs; a human approves the call through the tool-approval gate. ≥ 32 bytes. Without it those tools fail closed. Vault-hydrated from supacloud/app.
Variable Default Notes
SUPACLOUD_EDITION_LICENSE — HS256 JWT asserting edition=enterprise. Validated against SUPACLOUD_EDITION_SECRET. Vault-hydrated from supacloud/app.
SUPACLOUD_EDITION_SECRET — Signing secret for the edition license. ≥ 32 bytes. Vault-hydrated from supacloud/app.
SUPACLOUD_EDITION — Dev bypass only: set to enterprise together with MODE=dev to activate enterprise edition without a license token. Never use in production.
Variable Default Notes
AGENT_NETWORK supacloud-agents Docker network agent containers join.
SUPACLOUD_AGENT_NETWORK_ISOLATION per_task per_task gives every locally launched agent run its own Docker network that only the server and that run’s sidecars join. shared puts every agent on AGENT_NETWORK. Any other value is treated as per_task.
SUPACLOUD_HUB_CONTAINER $HOSTNAME The server’s own container (name or id) that joins each per-task agent network. With per_task isolation a launch fails closed when neither this nor HOSTNAME is set, for example when the server runs outside a container; use shared there.
AGENT_IMAGE_PREFIX — Registry prefix prepended to agent image names (e.g. git.blockworx.tech/blockworx/).
AGENT_IMAGE_DIGEST_NODE — The manifest digest (sha256:<64 hex>) the deploy verified for supacloud-agent-unified:node. When set, a launch of that channel pulls and runs …@sha256:… instead of the mutable tag, and the local tag is re-pointed at it. AGENT_IMAGE_DIGEST_LATEST falls back to this value.
AGENT_IMAGE_DIGEST_FULL — The same for :full; the per-language aliases (AGENT_IMAGE_DIGEST_{PYTHON,RUST,DOTNET,GO,JAVA}) fall back to it, because the build publishes them from the :full manifest.
AGENT_IMAGE_REQUIRE_DIGEST true when MODE=prod Refuse to launch a registry-qualified agent channel tag that has no digest pin. false opts out (a self-hosted deployment without a signing pipeline). A malformed pin always refuses, and an unqualified image name is never affected.
AGENT_MEMORY_BYTES 2147483648 Per-agent memory cap (bytes).
SUPACLOUD_HUB_AGENT_MEMORY_BUDGET_BYTES 0 (unlimited) Memory the hub may commit to agent containers that land there because no runner was eligible (a runner fallback). A fallback that would exceed it waits for a runner instead. 0 means unlimited.
SUPACLOUD_AGENT_NETWORK_DB_GUARD warn What the server does at boot when AGENT_NETWORK also carries the database host: warn logs an error and sets supacloud_agent_network_shares_db 1; refuse stops the boot in MODE=prod. Any other value means refuse.
AGENT_NANO_CPUS 2000000000 Per-agent CPU cap (nano-CPUs; 2 000 000 000 = 2 vCPUs).
AGENT_MEMORY_BYTES_HEAVY 2 × AGENT_MEMORY_BYTES Memory cap of a heavy resource-class container (bytes).
AGENT_NANO_CPUS_HEAVY 2 × AGENT_NANO_CPUS CPU cap of a heavy resource-class container (nano-CPUs). Clamped to the CPUs of the host that creates the container.
AGENT_CONCURRENCY_WEIGHT_HEAVY 2 How many of the workspace’s MAX_PARALLEL_TASKS_PER_WORKSPACE slots a heavy task occupies.
AGENT_PIDS_LIMIT 512 Per-agent PID limit.
AGENT_READ_ONLY_ROOTFS true Mount the agent root filesystem read-only.
AGENT_TMPFS_TMP_MB 512 Size ceiling for the agent’s /tmp tmpfs, in MiB.
AGENT_TMPFS_RUN_MB 64 Size ceiling for the agent’s /run tmpfs, in MiB.
AGENT_TMPFS_HOME_MB 512 Size ceiling for /home/agent — the CLIs’ config/state. Package-manager caches go to the per-task /workspace-cache volume on disk instead.
SUPACLOUD_AGENT_TEST_DB false Wand 6 option C — instance-level CAPABILITY gate for the per-task ephemeral Postgres sidecar. With it off no sidecar is ever created. With it on, a task gets a sidecar only when it opts in (task.config.test_db = true); a non-selected task gets none. An explicit caller TEST_DATABASE_URL wins: it is never overwritten and the sidecar is suppressed. The sidecar injects TEST_DATABASE_URL, its password (and full URL) is registered in the run’s redaction set, and it is removed with the agent container; a sidecar that cannot start prevents the agent container from starting, and a REQUESTED sidecar the server cannot resolve (a stored project override that no longer parses, a kind this build does not know) refuses the run with sidecar unavailable: … instead of launching without it - so a run never reports tests as green that never had a database (fail closed). The per-run decision, the resolved image AND the password ride the runner WorkPayload, so a dispatched run provisions the same sidecar and the hub’s relay redacts the same credential.
AGENT_TEST_DB_IMAGE postgres:18.6 Image for the SUPACLOUD_AGENT_TEST_DB sidecar.
AGENT_TASK_TIMEOUT_MINUTES 90 Hard timeout per agent task.
SUPACLOUD_HARNESS_FIRST_PROGRESS_SECS 600 (opencode: 90) Clock 1 of the progress guard for CLI harnesses (#838): how long a harness may make no progress at all after it starts. A breach stops the run and the task ends as harness_stalled, carrying the harness’s last stderr line. The default is per-adapter. codex, qwen, copilot, gemini-agy and openclaude keep 10 minutes, because before their first output “made no progress” and “wrote no byte” are the same statement and a short window there would just be a shorter fuse on the old watchdog. opencode takes 90 s, and only because it is measured: with --print-logs it emitted its first structured line within ~1 s of spawn in every captured run. 0 disables it; a malformed value falls back to the 10-minute default — wrong in the direction that cannot kill a working run.
SUPACLOUD_HARNESS_IDLE_CEILING_MINS 20 Clock 2 of the progress guard (#838): how long a started harness may go without further progress. Unlike clock 1 this is rolling — every piece of progress re-arms it — so it never caps a run that is working; that is AGENT_TASK_TIMEOUT_MINUTES’ job. A breach ends the task as harness_no_progress, carrying the step the harness was last in, when it last got anywhere and its own last line. Progress means a run event, a completed stdout line or a stderr line that is a new step — never merely that a byte arrived, which is what the pre-#838 watchdog measured and why a harness that narrated and then wedged was supervised by nobody. 0 disables it.
SUPACLOUD_HARNESS_LIVENESS_MINS (deprecated) The pre-#838 name for the start deadline. Still honoured, and it feeds both clocks: it sets the idle ceiling, and it widens clock 1 (never narrows it), so an operator who raised it to stop a slow-starting harness being killed keeps that protection instead of having it silently swapped for a shorter default. An explicit 0 still means “no deadline”, on both. Prefer the two names above.
SUPACLOUD_HARNESS_STARTUP_NOTICE_SECS 30 The non-fatal stage between the two progress clocks (#838): while a harness is making no progress, a visible but non-fatal notice is posted to the task feed saying how long it has been quiet, the step it is in, its last line, and which MCP servers the runner configured. Bounded to three notices for the whole run with a doubling wait (30 s, 60 s, 120 s), on the progress axis rather than the byte axis — so a harness that narrates and then wedges is reported, while one that keeps working is not nagged. It never stops a run; only the two clocks above do. 0 disables it; a malformed value falls back to the default.
OPENCODE_LOG_LEVEL INFO --log-level handed to the opencode CLI, which the runner always launches with --print-logs (#838). Without it opencode writes nothing to either stream until the model answers, so a slow provider is indistinguishable from a dead harness. INFO carries the bootstrap steps and the server unavailable warning for an MCP server that would not start; DEBUG, WARN and ERROR are the other accepted values. An unrecognised value falls back to INFO. The logs go to stderr only — the --format json event stream on stdout is unaffected.
MAX_PARALLEL_TASKS_PER_WORKSPACE 3 Concurrency cap per workspace.

Connector executor (ADR 0034 Decision 6 / #361)

Section titled “Connector executor (ADR 0034 Decision 6 / #361)”
Variable Default Notes
SUPACLOUD_CONNECTOR_EXECUTOR_MODE in_process in_process, pooled, or runner_fleet.
SUPACLOUD_CONNECTOR_EXECUTOR_IMAGE — Container image for pooled mode.
SUPACLOUD_CONNECTOR_EXECUTOR_AUTH_TOKEN — Shared token (≥ 16 chars) for pooled mode. Carried over the executor-only network.
SUPACLOUD_CONNECTOR_EXECUTOR_NETWORK — Dedicated Docker network for hub ↔ executor traffic in pooled mode.
SUPACLOUD_CONNECTOR_EXECUTOR_POOL_SIZE 2 Number of warm executor containers in pooled mode.
SUPACLOUD_CONNECTOR_EXECUTOR_MAX_INFLIGHT 4 Maximum concurrent in-flight runs in pooled mode.
SUPACLOUD_CONNECTOR_EXECUTOR_MAX_RUNS 0 Container recycling threshold in pooled mode. 0 = never recycle on run count.
SUPACLOUD_CONNECTOR_EXECUTOR_REQUEST_TIMEOUT_SECS 60 Maximum wait for a warm pool slot.
SUPACLOUD_SCRIPT_RUNTIME_DIR crate dev/test assets Absolute path to the pre-built Wasm script-runtime components (js-runner, ts-runner, py-runner). Unprovisioned languages degrade gracefully.
SUPACLOUD_DOCS_DIR /app/docs, else the in-repo docs/ Absolute path to the documentation corpus the docs.search / docs.get / spec.get MCP read tools serve. A relative value is ignored on purpose. With no corpus present the tools answer corpus_available: false.
Variable Default Notes
SUPACLOUD_HUB_MODE false Opt-in to dispatching tasks to a registered remote runner fleet. When false, every task runs locally.
SUPACLOUD_RUNNER_GRPC_ADDR 127.0.0.1:50061 Runner gRPC listen address (hub mode only). Loopback by default; a reachable address needs TLS or the explicit opt-in. The transport matrix lives in server/src/interfaces/grpc/server_security.rs.
SUPACLOUD_RUNNER_GRPC_TLS_CERT — PEM certificate chain path for native TLS on the runner gRPC listener. Needs SUPACLOUD_RUNNER_GRPC_TLS_KEY; one without the other refuses to start. The PEMs are parse-validated at boot.
SUPACLOUD_RUNNER_GRPC_TLS_KEY — PEM private key path for SUPACLOUD_RUNNER_GRPC_TLS_CERT.
SUPACLOUD_RUNNER_GRPC_TLS_CLIENT_CA — PEM CA bundle path; when set, the listener requires a client certificate signed by it (mTLS). Needs the cert/key pair.
SUPACLOUD_RUNNER_GRPC_INSECURE_H2C false Explicit opt-out to cleartext h2c on a non-loopback address (private tailnet only); logs a WARN at boot. Ignored when TLS is configured.
SUPACLOUD_E2E_TASK_SESSION_MINT false E2E bench capability: lets a workspace owner/admin mint a task’s agent session (POST /api/workspaces/{id}/tasks/{task_id}/e2e-session) so a bench driver can reach the agent-MCP surface without a database write. Refused at boot when MODE=prod; off, the route answers 404.
SUPACLOUD_HUB_EVENT_RELAY false Relay realtime hub events across server replicas over Postgres LISTEN/NOTIFY (the WS event fan-out, #623 P4). Relays control + signal event classes in batched NOTIFYs, an event over the 8000-byte payload cap by reference (hub_relay_payloads, ADR 0087); delivery_class in sc-hub decides. Inert on a single replica; enable for a multi-replica deployment.
MODEL_CATALOG_REFRESH_HOURS 24 How often the model catalog is refreshed (1–720).
SUPACLOUD_CALIBRATION_BOARDS agent/latest/overall,webdev/latest/overall,text/latest/overall Which LMArena leaderboards the tier-chain calibration reads, comma-separated, as config[/split[/category[/shape[/max_rows]]]]. shape is rating (Elo boards) or score (the agent family) and defaults to rating; * in the category position reads every category; max_rows caps the read depth (default 600, measured to cover every default board’s overall block). Each board gets its own metric token, its own snapshot row and its own fold report. A malformed entry is a hard error naming it — it never falls back to the defaults. An entry may be prefixed modality: (vision, image, video, speech, music, model3d) — e.g. image:t2i/latest/overall — which scopes its metric token and its snapshot row to that modality, so it can only feed that modality’s tier and can never move a text tier’s ranking. No prefix means text, so every existing value keeps its exact meaning. An unknown modality word is a hard error naming it.
SUPACLOUD_CALIBRATION_TIER_WEIGHTS built-in per tier Per-tier axis weights for the calibration frontier, comma-separated, as tier:quality/cost/speed (e.g. fast:0.2/0.5/0.3). A tier the value does not name keeps its built-in weights. The numbers are RATIOS, not shares — the frontier re-bases them over the axes a model is actually measured on. Instance-wide; a per-workspace override is not available. The lane tiers (vision_judge, image_gen, video_gen, speech_gen, music_gen, model3d_gen, security_review) are named the same way.
Variable Default Notes
SUPACLOUD_MANAGEMENT_API_TOKEN — Bearer token granting access to the M2M management API. Also accepted as MANAGEMENT_API_TOKEN (legacy). Vault-hydrated from supacloud/management.
Variable Default Notes
TELEGRAM_BOT_TOKEN — Telegram control-bot token. Vault-hydrated from supacloud/messaging. Bot is disabled when unset.
TELEGRAM_BOT_USERNAME — Telegram bot username (without @). Vault-hydrated.
DISCORD_BOT_TOKEN — Discord control-bot token (ADR 0032). Vault-hydrated from supacloud/app. Bot is disabled when unset. Distinct from per-workspace Discord notify/trigger resources.
Variable Default Notes
SUPACLOUD_SMTP_HOST — SMTP relay hostname. When unset the global SMTP transport is disabled; workspace SMTP resources still work.
SUPACLOUD_SMTP_PORT 587 SMTP port.
SUPACLOUD_SMTP_USE_TLS true Enable TLS.
SUPACLOUD_SMTP_STARTTLS true Use STARTTLS.
SUPACLOUD_SMTP_USERNAME — SMTP auth username.
SUPACLOUD_SMTP_PASSWORD — SMTP auth password. Vault-hydrated from supacloud/app.
Variable Default Notes
SUPACLOUD_APPS_HOSTED_FRONTEND false Enable serving of built React/Svelte App frontends. Requires SUPACLOUD_APPS_BASE_DOMAIN.
SUPACLOUD_APPS_BASE_DOMAIN — Bare domain (e.g. supacloud.net) on a different eTLD+1 than the control plane. Hosted Apps are served at <opaque-subdomain>.<apps_base_domain>. Boot fails if this shares a registrable domain with PUBLIC_URL.
Variable Default Notes
SUPACLOUD_LINEAR_OAUTH_CLIENT_ID — Linear OAuth app client ID. Vault-hydrated.
SUPACLOUD_LINEAR_OAUTH_CLIENT_SECRET — Linear OAuth app client secret. Vault-hydrated.
SUPACLOUD_NOTION_OAUTH_CLIENT_ID — Notion OAuth app client ID. Vault-hydrated.
SUPACLOUD_NOTION_OAUTH_CLIENT_SECRET — Notion OAuth app client secret. Vault-hydrated.
Variable Default Notes
STRIPE_SECRET_KEY — Stripe API secret key. Vault-hydrated from supacloud/app.
STRIPE_WEBHOOK_SECRET — Stripe webhook signing secret. Vault-hydrated from supacloud/app.
BW_FINTS_WORKER_API_KEY — Internal API key for the marketplace FinTS payout worker. Vault-hydrated from supacloud/app.
SUPACLOUD_OPERATOR_TOKEN — Operator bearer token for privileged internal calls. Vault-hydrated from supacloud/app.
SUPACLOUD_METRICS_TOKEN — Bearer token protecting the /metrics endpoint. Vault-hydrated from supacloud/app.