Server configuration reference
Operational settings of the RootTrace server container can be overridden with environment variables at startup (docker run -e or Compose environment:). Most are read once at process start. The selected deployment security profile is also stored through the platform-admin UI and validated against the running configuration before the update is accepted. The database-backed profile and JWT algorithm do not require an API restart. This page lists the operator-facing variables for an on-prem deployment. For the supported end-to-end path, start with the Docker Compose install guide.
Select the server image from the RootTrace Server Amazon ECR Public Gallery. The public Gallery shows the supported tags and pull commands. Air-gapped installations must mirror that image and the RootTrace Agent image before configuring the server to generate collector install instructions.
Minimal configuration
Configure these runtime connectivity settings before first use. Browser identity, the application secret, the first-owner bootstrap token, and the metrics token are also required for the production first-boot flow described in the install guide.
| Variable | Default | Why you set it |
|---|---|---|
ROOTTRACE_MONGO_URI | mongodb://localhost:27017 | MongoDB connection string; the localhost default is useless inside a container. Compose constructs this from the application Mongo credentials. The unprefixed MONGO_URI is accepted as a legacy alias. |
ROOTTRACE_SECURITY_PROFILE | regulated in production; default otherwise | Startup baseline: default, regulated, or air_gapped. The platform-admin UI can store the next-startup value. |
ROOTTRACE_ELASTICSEARCH_HOST | empty on-prem | HTTPS Elasticsearch URL backing AI and semantic search. Leave empty to disable those features. Regulated profiles reject a non-HTTPS URL. |
ROOTTRACE_FORWARDED_ALLOW_IPS | 127.0.0.1,::1 | Exact upstream addresses allowed to set X-Forwarded-*. Never use * with a regulated profile. The bundled compose uses its fixed nginx address. |
ROOTTRACE_APM_TOKEN | unset | Collector token that turns on the server's own APM self-monitoring (falls back to ROOTTRACE_COLLECTOR_TOKEN). Unset means no self-monitoring. |
ROOTTRACE_API_URL | http://127.0.0.1:<listen port>/api | Where that self-monitoring data flushes. It defaults to this server's own listener, so self-monitoring never leaves the deployment. |
The supported Compose stack supplies these settings, runs MongoDB on an internal-only network, mounts the application-secret file, and terminates TLS at nginx. Set its required values in deploy/.env; do not copy a partial standalone docker run command into production.
Where settings come from
On-prem, there is one source: the container environment. Compose reads deploy/.env and maps selected values in; the application never opens that file itself.
An on-prem image does not contact AWS Systems Manager Parameter Store unless you explicitly set a prefix. Leave these unset; the supported Compose stack and every air-gapped deployment do:
| Variable | Meaning |
|---|---|
ROOTTRACE_SSM_PARAMETER_PREFIX | Opt in to Parameter Store and select the path, e.g. /roottrace/staging. Unset on-prem. |
ROOTTRACE_SSM_REGION | Region for that client, when the normal AWS SDK Region is not right. |
If you do opt in: parameters live one per Standard SecureString under the prefix, names must begin with ROOTTRACE_, and an existing environment variable always wins over the same-named parameter, even when it is empty. Parameter Store only fills what the environment left missing. The workload role needs ssm:GetParametersByPath on that path and nothing more. scripts/import_env_to_parameter_store.py migrates an existing env file (--dry-run first; it prints names, never values).
Conventions
- Booleans accept
1,true,yes,on(case-insensitive). - List values are comma-separated.
- Integer variables are parsed strictly; a non-numeric value fails startup.
- Published images have
cloudoron_premcompiled into a root-owned, read-only native module. There is no runtime deployment-mode setting. Packaged startup fails if the marker is missing or invalid. A source checkout may useROOTTRACE_DEPLOYMENT_MODEfor local development; Docker uses the same name only as a build argument.
Core runtime
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_ENVIRONMENT | dev | Set prod for real deployments. Flips defaults for allowed origins, rate limiting, strict Mongo sharding, and the security profile. A published on-prem image runs the production startup checks whatever this says, so the value selects those defaults and nothing more. |
ROOTTRACE_SECURITY_PROFILE | regulated in production; default otherwise | default, regulated, or air_gapped. Regulated profiles fail startup on unsafe combinations. A platform admin can select a stored profile in Flutter; the API validates the running configuration and applies the selection immediately or rejects it. |
ROOTTRACE_LOG_LEVEL | info | Root logger level; also the default floor for APM log shipping. |
ROOTTRACE_LISTEN_HOST | 0.0.0.0 | Bind host. |
ROOTTRACE_LISTEN_PORT | 8090 | Bind port (the image exposes 8090; /readyz is the health endpoint). |
ROOTTRACE_API_WORKERS | 0 (auto) | Worker count; 0 means CPU count minus ROOTTRACE_EMBEDDING_RESERVED_CPU_CORES, minimum 1. |
ROOTTRACE_FORWARDED_ALLOW_IPS | 127.0.0.1,::1 | Exact upstreams allowed to set X-Forwarded-* (passed to uvicorn). The bundled Compose default is 10.233.1.10; change it together with ROOTTRACE_NGINX_IP. |
ROOTTRACE_WEB_DIR | bundled UI | Override the path of the bundled dashboard web build. |
ROOTTRACE_INSTALLATION_ID | empty | On-prem licensing identifier. Use the exact id from a portal-issued license. Leave empty only when the license will be issued against the id generated after first boot. |
Do not set ROOTTRACE_SKIP_STARTUP_BOOTSTRAP, ROOTTRACE_RUN_EMBEDDING_WORKER_IN_API, or ROOTTRACE_EMBEDDING_SERVICE_MODE: the server's own bootstrap process manages these for its worker and sidecar children.
Data stores
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_MONGO_URI | mongodb://localhost:27017 | MongoDB connection string. Required in practice. |
ROOTTRACE_MONGO_DATABASE | roottrace | Database name. |
ROOTTRACE_MONGO_MIN_POOL_SIZE / MAX_POOL_SIZE | 0 / 100 | Connection pool bounds. |
ROOTTRACE_MONGO_SERVER_SELECTION_TIMEOUT_MS | 5000 | Server selection timeout. |
ROOTTRACE_ENABLE_MONGO_SHARDING | true | Attempt sharded-cluster bootstrap. Set false for single-node Mongo (the compose file does). |
ROOTTRACE_MONGO_SHARDING_STRICT | true in prod | Fail hard versus warn when sharding setup fails. |
ROOTTRACE_ELASTICSEARCH_HOST | empty on-prem | HTTPS Elasticsearch URL backing AI and semantic search. Empty cleanly disables those features. Regulated profiles reject plaintext HTTP. |
ROOTTRACE_ELASTICSEARCH_ALLOW_INSECURE | false | Permit a plaintext Elasticsearch URL under a regulated profile. Use only when transport security is enforced elsewhere. |
Security and auth
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_APP_SECRET | generated | Master application secret. If unset and no file is given, one is generated and persisted in Mongo. |
ROOTTRACE_APP_SECRET_FILE | empty | Path to a mounted secret file (Kubernetes/Vault style). The inline variable wins when both are set. |
ROOTTRACE_BOOTSTRAP_TOKEN | empty | Operator-held token required to claim the first local owner. It must be at least 32 characters on every on-prem installation: a published on-prem image refuses to start below that, and a source checkout outside production rejects the first-owner claim at sign-up instead. Generate it with openssl rand -hex 32. It cannot claim another account afterward; retain it as break-glass proof because local password recovery requires it together with TOTP or a recovery code. |
ROOTTRACE_ADMIN_EMAILS | empty | Comma-separated platform-admin email allowlist. Set this before upgrading an email-first on-prem installation so its legacy platform admins retain access. Fresh local-username owners are platform admins automatically and do not need it. |
ROOTTRACE_SSL_CERTFILE / ROOTTRACE_SSL_KEYFILE | empty | In-app TLS termination; both must be set to take effect. Leave empty behind the bundled nginx. |
ROOTTRACE_JWT_ALGORITHM | ML-DSA-65 (RS256 when FIPS mode is enabled) | Environment default for token signing. A platform admin can store ML-DSA-44, ML-DSA-65, ML-DSA-87, EdDSA, RS256, or ES256 in Flutter without restarting the API; the database selection wins and changing it immediately rotates to a newly generated key. Every API replica reads the selection and active keys from MongoDB. The ML-DSA choices are post-quantum. Current validated-provider FIPS mode requires RS256 or ES256. |
ROOTTRACE_JWT_ISSUER / ROOTTRACE_JWT_AUDIENCE | empty on-prem / roottrace-api | Token issuer and audience. The issuer is required on-prem and must equal the HTTPS origin of ROOTTRACE_PUBLIC_API_URL; startup fails otherwise. |
ROOTTRACE_FIPS_MODE | false | Fail startup unless the configured JWT primitive and active OpenSSL provider satisfy the enforced FIPS checks. |
ROOTTRACE_ACCESS_TOKEN_MINUTES | 60 (cap 7200) | Access token TTL. |
ROOTTRACE_REFRESH_TOKEN_DAYS | 5 (cap 5) | Refresh token TTL. |
ROOTTRACE_PASSWORD_RESET_MINUTES | 30 | Password-reset token lifetime. |
ROOTTRACE_EMAIL_CONFIRMATION_MINUTES | 60 | Email-confirmation token lifetime. |
ROOTTRACE_EMAIL_MFA_CODE_MINUTES / _LENGTH | 10 / 6 | Email MFA code lifetime and digit count. |
ROOTTRACE_SESSION_IDLE_TIMEOUT_MINUTES | 0 (off) | Idle-session termination (STIG SRG-APP-000295). |
ROOTTRACE_LOGIN_LOCKOUT_THRESHOLD / LOCKOUT_MINUTES | 10 / 15 | Failed-login lockout. |
ROOTTRACE_REQUIRE_PRIVILEGED_MFA | true | Require an enrolled MFA factor for admin and owner accounts. The local-owner setup flow guides operators to TOTP because it does not depend on email. |
ROOTTRACE_PASSWORD_REQUIRE_COMPLEXITY | true on-prem | Require at least 12 characters with an uppercase letter, lowercase letter, digit, and symbol. |
ROOTTRACE_PASSWORD_HISTORY_COUNT | 5 | Block reuse of the last N passwords. |
ROOTTRACE_BREACHED_PASSWORD_CHECK | true hosted; ignored on-prem | Enables HaveIBeenPwned screening for hosted-cloud password flows. On-prem code never makes this call, regardless of the value. |
ROOTTRACE_ACCOUNT_INACTIVITY_DISABLE_DAYS | 0 (off) | Auto-disable idle accounts (DoD baseline: 35). |
ROOTTRACE_ALLOWED_ORIGINS | roottrace.io origins in prod | CSV CORS allowlist; set to your dashboard origin. |
ROOTTRACE_ALLOWED_ORIGIN_REGEX | empty | CORS origin regex. |
ROOTTRACE_TRUSTED_PROXY_CIDRS | 127.0.0.1/32,::1/128 | CIDRs whose forwarded headers are trusted for client IP. |
ROOTTRACE_TRUST_CDN_CLIENT_IP_HEADERS | false | Trust CF-Connecting-IP / True-Client-IP; enable only behind a CDN that sets them, otherwise IP allowlists become spoofable. |
ROOTTRACE_WEBAUTHN_RP_ID | public app host | Passkey relying-party domain. Set this when using a custom dashboard domain. |
ROOTTRACE_WEBAUTHN_RP_NAME | RootTrace | Passkey relying-party display name. |
ROOTTRACE_WEBAUTHN_ORIGINS | public app origin | Exact comma-separated browser origins allowed for passkey ceremonies. |
ROOTTRACE_WEBAUTHN_REQUIRE_USER_VERIFICATION | true | Require authenticator biometric/PIN verification for passkeys. |
The API exposes WebAuthn enrollment and assertion endpoints, but the current Flutter client does not yet manage passkeys. Use TOTP for accounts operated through the shipped client. A passkey-only account can use one of its saved single-use recovery codes at login.
Workspace security administration
Workspace owners and admins configure tenant-applicable controls in Flutter under Settings → Security & Compliance:
security_profile:default,regulated, orair_gapped- privileged MFA
- idle-session timeout
- failed-login threshold and lockout duration
- concurrent-session cap
- inactive-account disable period
- logon consent banner and text
Blank numeric values inherit the deployment defaults. For users in several workspaces, RootTrace applies the strictest applicable session/account value.
The same screen shows the effective deployment profile, FIPS/JWT and WebAuthn state, token lifetimes, password policy, rate limiting, audit chaining, external-secret and metrics authentication posture, request limits, embedding/email posture, Elasticsearch TLS, proxy/CDN trust, browser origins, private egress exceptions, collector-token lifetime, and direct TLS. Those values are read-only to workspace admins because they belong to the shared API process. Changing them per tenant would not reconfigure the proxy, OpenSSL provider, or server socket. Platform admins can select the deployment security profile and JWT signing algorithm in Flutter without restarting the API. The profile is accepted only when the current process controls satisfy it. JWT changes rotate the shared database signing key before the update returns.
Licensing
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_LICENSE_ISSUER / AUDIENCE | https://roottrace.io / roottrace-on-prem | Expected license claims. |
ROOTTRACE_LICENSE_KMS_KEY_ID | alias/roottrace-license-signing | RootTrace Cloud only. AWS KMS key ARN, key id, or alias for the ECC_NIST_P256 SIGN_VERIFY license key. |
ROOTTRACE_LICENSE_KMS_REGION | AWS_REGION, then AWS_DEFAULT_REGION, then us-east-1 | AWS region containing the license signing key. |
The verification key is compiled into src/roottrace_license.py. The private key never leaves AWS KMS. The RootTrace Cloud runtime identity needs kms:Sign and kms:GetPublicKey on that key. Customer installs need no AWS credentials. ROOTTRACE_FIPS_MODE=true makes the KMS client use the regional AWS FIPS endpoint.
Grant the RootTrace Cloud runtime role only the operations it uses:
{
"Version": "2012-10-17",
"Statement": [{
"Sid": "SignRootTraceLicenses",
"Effect": "Allow",
"Action": ["kms:Sign", "kms:GetPublicKey"],
"Resource": "arn:aws:kms:us-east-1:123456789012:key/REPLACE_WITH_KEY_ID"
}]
}For local cloud development, configure a named AWS CLI profile, preferably through IAM Identity Center, and expose only its name and the non-secret configuration to the process:
aws configure sso --profile roottrace-license-signing
aws sso login --profile roottrace-license-signing
export AWS_PROFILE=roottrace-license-signing
export AWS_DEFAULT_REGION=us-east-1
export ROOTTRACE_LICENSE_KMS_KEY_ID=alias/roottrace-license-signing
export ROOTTRACE_LICENSE_KMS_REGION=us-east-1Confirm the profile and then start the source checkout in cloud mode from the same shell:
aws sts get-caller-identity --profile roottrace-license-signing
export ROOTTRACE_DEPLOYMENT_MODE=cloudRootTrace reads the process environment and does not load .env_dev or another dotenv file itself. The launcher must export these values before importing the application.
The profile belongs to that host user. A container does not inherit the host's AWS profile. Do not work around that by mounting credentials or passing access keys into the customer Compose stack: the published on-prem image cannot issue licenses. Run local cloud development as the configured host user, or attach a workload role to the cloud compute service.
Do not write AWS access or session keys to a dotenv file or Parameter Store. Production cloud deployments use their workload identity. Customer on-prem deployments do not receive these settings.
Setting ROOTTRACE_SMTP_HOST switches all mail to direct SMTP through your relay, bypassing every cloud path. Leaving it empty with the relay disabled means email is simply not sent.
On an empty on-prem database, the first owner can register with a local username, the configured bootstrap token, and no email address. The account is confirmed locally, public registration locks automatically, and the account has no email password-reset path. Keep the bootstrap token in the deployment secret manager and enroll TOTP; password recovery requires both that token and a current authenticator or recovery code. Later password-based users need SMTP-backed invitations. Sites without SMTP must provision users and memberships with SCIM; SSO alone does not create an account.
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_EMAIL_SENDING_ENABLED | false on-prem; true otherwise | Global outbound-email switch. |
ROOTTRACE_SMTP_HOST | empty | SMTP relay host; non-empty gates the SMTP path. |
ROOTTRACE_SMTP_PORT | 587 | Relay port. |
ROOTTRACE_SMTP_USERNAME / ROOTTRACE_SMTP_PASSWORD | empty | Relay credentials. |
ROOTTRACE_SMTP_STARTTLS / ROOTTRACE_SMTP_SSL | true / false | STARTTLS, or implicit TLS. |
ROOTTRACE_SMTP_TIMEOUT_SECONDS | 15 | Send timeout. |
ROOTTRACE_EMAIL_FROM_ADDRESS / FROM_NAME / REPLY_TO | RootTrace defaults | Sender identity; OEM installs should override. |
ROOTTRACE_ON_PREM_EMAIL_RELAY_ENABLED | false | Opt-in relay through the vendor cloud; keep false when air-gapped. |
AI, LLM, and embeddings
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_LLM_PROVIDER | anthropic | anthropic, openai_compatible (self-hosted or any OpenAI-standard endpoint), or disabled (deterministic local fallback, no LLM calls). |
ROOTTRACE_CLAUDE_API_KEY | empty | Anthropic API key (ANTHROPIC_API_KEY also accepted); empty leaves the Anthropic path inert. |
ROOTTRACE_CLAUDE_RECOMMENDATION_MODEL | claude-sonnet-5 | Model id (also the default model for the OpenAI-compatible path). |
ROOTTRACE_CLAUDE_BASE_URL | empty | Proxy or gateway base URL for the Anthropic path (in-network for air-gapped installs). |
ROOTTRACE_LLM_OPENAI_BASE_URL | empty | Base URL of an OpenAI-compatible server (Ollama, vLLM, llama.cpp, NVIDIA NIM); /chat/completions is appended. Required when the provider is openai_compatible. |
ROOTTRACE_LLM_OPENAI_MODEL | empty | Model name sent to the OpenAI-compatible server. |
ROOTTRACE_LLM_OPENAI_API_KEY | empty | Optional bearer token for that server. |
ROOTTRACE_OPENAI_TIMEOUT_SECONDS | 20 | LLM request timeout in seconds. Increase it for slower local models. |
ROOTTRACE_EMBEDDING_OFFLINE | true on-prem | Never download the embedding model at runtime; sets the HuggingFace offline flags. |
ROOTTRACE_EMBEDDING_MODEL_PATH | empty | Optional replacement model directory. The on-prem image already contains the default model; leave this unset unless mounting a tested replacement. |
ROOTTRACE_EMBEDDING_MODEL | sentence-transformers/all-mpnet-base-v2 | Model id (baked into the on-prem image). |
ROOTTRACE_EMBEDDING_DEVICE | auto | Torch device. |
ROOTTRACE_EMBEDDING_CPU_THREADS / WORKER_THREADS | 1 / 1 | Embedding compute threads. |
ROOTTRACE_EMBEDDING_RESERVED_CPU_CORES | 1 | Cores reserved for the managed local embedding process; also feeds the auto worker count. |
ROOTTRACE_EMBEDDING_MODEL_SERVICE_ENABLED | true | Run the managed embedding model service beside the API. This is a loopback-only internal process, not a supported remote-offload endpoint. |
ROOTTRACE_EMBEDDING_MODEL_SERVICE_HOST / PORT | 127.0.0.1 / launcher-selected | Local model-service listener. The host must remain loopback; the launcher assigns a port when zero. |
ROOTTRACE_PRELOAD_EMBEDDING_MODEL | true | Load the model at startup. |
ROOTTRACE_EMBEDDING_LIFECYCLE_ENABLED | false in Compose (true application default) | Attach the current index-age ILM policy. Keep the shipped Compose default off until it is replaced with document-safe retention; see the sizing guide. |
ROOTTRACE_EMBEDDING_LIFECYCLE_POLICY | roottrace-vector-retention | Base name for generated Elasticsearch lifecycle policies. |
ROOTTRACE_EMBEDDING_RETENTION_DAYS | 365 | Fallback vector-document and lifecycle age when no workspace retention is supplied. |
The OpenAI-compatible base URL is resolved from inside the API container or pod. Use the model server's network hostname. localhost only works when the model server shares the API container's network namespace.
The image also disables all third-party telemetry unconditionally (DO_NOT_TRACK, HF_HUB_DISABLE_TELEMETRY, and related flags).
Self-monitoring (APM)
The server can monitor itself with the same APM pipeline your own services use.
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_APM_TOKEN | unset | Collector token enabling self-monitoring (falls back to ROOTTRACE_COLLECTOR_TOKEN); unset leaves it off. |
ROOTTRACE_API_URL | http://127.0.0.1:<listen port>/api | Where APM data flushes. The server passes this explicitly rather than inheriting the SDK's cloud default, so an unset value keeps self-monitoring on the loopback interface. |
ROOTTRACE_APM_SERVICE | roottrace-api | Reported service name. |
ROOTTRACE_APM_INTERVAL_SECONDS | 30 | Flush interval. |
ROOTTRACE_APM_LOGS | on | Set false to disable log shipping. |
ROOTTRACE_APM_LOG_LEVEL | ROOTTRACE_LOG_LEVEL | Minimum level shipped. |
The Compose template passes all six settings and defaults ROOTTRACE_API_URL to http://127.0.0.1:8090/api, keeping self-monitoring inside the API container. After first sign-in, create a collector token and set it as ROOTTRACE_APM_TOKEN; leave the token empty to keep self-monitoring disabled.
Rate limiting and ingest
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_RATE_LIMIT_ENABLED | true in prod | Per-client API rate limiting. |
ROOTTRACE_RATE_LIMIT_REQUESTS_PER_MINUTE | 120 | The limit. |
ROOTTRACE_RATE_LIMIT_BACKEND | memory | memory is per-process; use mongo when running multiple workers or replicas. |
ROOTTRACE_COLLECTOR_INGEST_RATE_LIMIT_ENABLED | true | Per-collector ingest floor. |
ROOTTRACE_COLLECTOR_INGEST_MIN_INTERVAL_SECONDS | 45 | Minimum interval between a collector's ingests. |
Collectors and fleet
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_COLLECTOR_HEARTBEAT_EXPECTED_SECONDS | 180 | Staleness threshold before a collector counts as missing. |
ROOTTRACE_COLLECTOR_TOKEN_TTL_DAYS | 0 (never) | Enrollment token expiry. |
ROOTTRACE_COLLECTOR_TOKEN_ROTATION_OVERLAP_HOURS | 24 | Grace period in which a replaced collector token remains valid. |
ROOTTRACE_COLLECTOR_IMAGE | empty; required by Compose | Immutable agent index digest from the manifest inside the signature-verified deployment archive. The air_gapped profile also accepts the bundle's exact roottrace-airgap/agent:sha256-… offline tag. |
ROOTTRACE_APM_ALERT_AUTO_RESOLVE_ENABLED / _SECONDS | true / 900 | Auto-resolve stale APM issues. |
Retention and audit
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_SERVER_RECORD_RETENTION_DAYS | 365 | Telemetry retention (license and plan can clamp it; on-prem 0 means unlimited via the license catalog). |
ROOTTRACE_AUDIT_RETENTION_DAYS | 365 (floor 30) | Security audit event retention, independent of plan retention. |
ROOTTRACE_AUDIT_HASH_CHAIN_ENABLED | true | Tamper-evident audit hash chaining. |
ROOTTRACE_AUDIT_SYSLOG_ENABLED | false | RFC 5424 forwarding to a SIEM. |
ROOTTRACE_AUDIT_SYSLOG_HOST / PORT / PROTOCOL | empty / 514 / udp | Syslog target (tcp supported). |
Webhooks and notifications
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_WEBHOOK_MAX_ATTEMPTS | 5 | Delivery attempts. |
ROOTTRACE_WEBHOOK_RETRY_BASE_SECONDS | 30 | Backoff base. |
ROOTTRACE_NOTIFICATION_ALLOW_INSECURE_WEBHOOKS | false | Allow plaintext or unverified-TLS webhook targets. |
ROOTTRACE_NOTIFICATION_CA_BUNDLE | empty | Custom CA bundle path (mount the file into the container) for webhook TLS. |
ROOTTRACE_OUTBOUND_ALLOWED_PRIVATE_CIDRS | empty | Comma-separated private CIDRs that webhooks and repository SSH links may contact. Private destinations are blocked unless listed. |
Webhook URLs must use HTTPS by default and cannot contain URL credentials. The HTTP client checks every DNS answer on every connection, does not cache DNS, and applies the same policy after redirects. Responses are bounded before parsing or recording.
ROOTTRACE_NOTIFICATION_ALLOW_INSECURE_WEBHOOKS=true permits HTTP webhook URLs and disables webhook TLS verification. It does not permit private destinations. For an internal receiver you must separately list its network in ROOTTRACE_OUTBOUND_ALLOWED_PRIVATE_CIDRS.
Example for two explicitly approved internal networks:
ROOTTRACE_OUTBOUND_ALLOWED_PRIVATE_CIDRS=10.40.8.0/24,fd00:40:8::/64Use narrow service subnets. Do not allow metadata, loopback, or an entire VPC when a smaller range is available.
API request and metrics security
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_API_MAX_REQUEST_BODY_BYTES | 16777216 | Maximum buffered request body before the API returns HTTP 413. |
ROOTTRACE_API_MAX_STREAM_BODY_BYTES | 67108864 | Maximum body for the two NDJSON collector stream endpoints. |
ROOTTRACE_METRICS_BEARER_TOKEN | empty | Bearer token required by /metrics. Outside development mode, /metrics is disabled when this is empty. |
The request limits are enforced while reading the ASGI body, before FastAPI, Pydantic, JSON, protobuf, or webhook-signature parsing. They apply to requests with Content-Length and to chunked transfer encoding. Endpoint-specific ceilings remain stricter for client errors, log ingest, OTLP, and Stripe webhooks. A reverse proxy can impose a lower limit; keep its tested body limit at least as large as the largest enabled ingest request.
Configure a high-entropy metrics token through the deployment's secret manager:
ROOTTRACE_METRICS_BEARER_TOKEN="$(openssl rand -hex 32)"
curl -fsS \
-H "Authorization: Bearer $ROOTTRACE_METRICS_BEARER_TOKEN" \
http://127.0.0.1:8090/metrics/readyz and /healthz/ remain unauthenticated so orchestrator probes can use them. Keep both on an internal listener or restrict them at the proxy/firewall.
Repository links
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_VCS_CACHE_DIR | /var/tmp/roottrace-vcs | Git mirror cache directory (the compose file mounts a volume here). |
ROOTTRACE_VCS_MIRROR_MAX_BYTES / CACHE_MAX_BYTES | 1 GiB / 2 GiB | Cache size bounds. |
ROOTTRACE_VCS_MIRROR_MAX_AGE_DAYS | 30 | Mirror expiry. |
There is no SSH identity to configure here. Each repository link carries its own deploy key, generated in the app when you create the link; you install the public half as a read-only deploy key on the repository host. Nothing else in the server opens an SSH connection.
Repository SSH destinations use the same private-network CIDR policy as webhooks. Before ls-remote, clone, or fetch, RootTrace resolves every address, rejects the destination if any answer is non-public and not explicitly allowed, and pins SSH to the validated address while retaining the original hostname for host-key verification.
Branding, OEM, and public URLs
| Variable | Default | Meaning |
|---|---|---|
ROOTTRACE_PRODUCT_NAME | RootTrace | Product name in the UI and email. |
ROOTTRACE_VENDOR_MARKETING_ENABLED | true (compose: false) | Suppress vendor marketing surfaces on OEM installs. |
ROOTTRACE_SUPPORT_EMAIL / TERMS_URL / PRIVACY_URL | RootTrace defaults | Support and legal links. |
ROOTTRACE_PUBLIC_APP_URL | empty on-prem | Externally visible dashboard URL. Required: an on-prem server refuses to start in production without an HTTPS value. |
ROOTTRACE_PUBLIC_API_URL | empty on-prem | Externally visible API base. Required, same rule. |
Compose-level variables
These are read by deploy/docker-compose.yml itself (interpolation), not by the application:
| Variable | Default | Meaning |
|---|---|---|
MONGO_IMAGE / NGINX_IMAGE | pinned in deploy/.env.example | Reviewed third-party image digest references. |
ROOTTRACE_IMAGE / ROOTTRACE_COLLECTOR_IMAGE | required | RootTrace release image digest references. |
ROOTTRACE_PULL_POLICY | missing | Compose pull policy; the air-gapped bundle sets never. |
MONGO_ROOT_USER / MONGO_ROOT_PASSWORD | user defaults; password required | Mongo bootstrap administrator credentials. |
MONGO_APP_USER / MONGO_APP_PASSWORD | user defaults; password required | Least-privilege application credentials interpolated into the Mongo URI. |
MONGO_CACHE_GB | 1 | WiredTiger cache size. |
HTTPS_PORT | 443 | Host port for the nginx TLS listener. |
ROOTTRACE_APP_SECRET_HOST_PATH | ./secrets/app_secret | Host path mounted as the application secret. |
ROOTTRACE_DATA_SUBNET / ROOTTRACE_APP_SUBNET | private /24 networks | Override both if they overlap site networks. |
ROOTTRACE_NGINX_IP / ROOTTRACE_API_IP | addresses in the app subnet | Stable proxy and API addresses. Keep proxy trust values aligned with the nginx address. |
ROOTTRACE_APP_NETWORK_INTERNAL | false | Set true to remove external routing from the application network. |
Cloud-internal variables
These drive the hosted service and do nothing on an on-prem install. Leave them unset; they are listed only so you can recognize them in a settings dump.
| Variable group | Purpose |
|---|---|
ROOTTRACE_SENDGRID_* | Cloud email transport. On-prem uses ROOTTRACE_SMTP_* instead. |
ROOTTRACE_CLOUD_EMAIL_RELAY_URL, ROOTTRACE_ADMIN_EVENT_EMAIL | Vendor-side relay and notification address. |
ROOTTRACE_STRIPE_MODE | sandbox or production billing. |
ROOTTRACE_STRIPE_{SANDBOX,PRODUCTION}_{PUBLISHABLE_KEY,SECRET_KEY,WEBHOOK_SECRET} | Stripe credentials. |
ROOTTRACE_STRIPE_{STARTUP,GROWTH,SCALE}_{SANDBOX,PRODUCTION}_{PRICE_ID,PRODUCT_ID} | Per-tier Stripe identifiers. |
ROOTTRACE_STRIPE_SUCCESS_URL / CANCEL_URL / BILLING_PORTAL_RETURN_URL | Checkout redirect overrides. |