Configuration
All configuration for a self-hosted install lives in one file:
/opt/factorythread/current/.env.deploy
It's generated on first install with all secrets and sensible defaults. Every
key is documented in the shipped .env.deploy.example.
Edit .env.deploy, then run sudo ./ftctl restart. It does a full recreate so
new values (including network-level settings like NETWORK_MTU) take effect, but
keeps all volumes — the database and uploads are safe.
Defaulted endpoints
These are pre-set to the FactoryThread values — a standard install needs no input for them (override with the matching install flags if you must):
| Key | Default |
|---|---|
AUTH0_DOMAIN | factorythread.us.auth0.com |
AUTH0_AUDIENCE | api.factorythread |
AUTH0_REDIRECT_URL | https://app.factorythread.com/auth/login |
CONTROL_SERVICE_URL | https://control.factorythread.com |
FRONTEND_URL | https://app.factorythread.com |
Optional capabilities (the install prompts)
On a fresh install you're asked yes/no about each of these. Answering No keeps defaults; Yes walks the keys, and blank keeps the current value.
File storage
Where uploads and local (flat) files live, on the host and inside the container.
| Key | Purpose |
|---|---|
UPLOAD_STORAGE_TYPE | local or azure |
UPLOAD_LOCAL_BASE_PATH / UPLOAD_HOST_PATH | upload paths (container / host) |
LOCALFILE_BASE_PATH / LOCALFILE_HOST_PATH | flat-file paths (container / host) |
LOCALFILE_FOLDERS | comma-separated folder names |
Folder lists are comma-separated and tolerate spaces in names, e.g.
LOCALFILE_FOLDERS=dataFiles,Monthly Reports,Q1 Exports.
Worker memory
Protects the host from a runaway worker.
| Key | Default | Meaning |
|---|---|---|
WORKER_MEMORY | 8g | hard container memory cap |
WORKER_NODE_HEAP_MB | 6656 | Node.js old-space heap (≈ 80% of the cap) |
Keep the heap below the container cap so Node stays within the limit rather than being OOM-killed.
FactoryThread Assistant (AI)
Enables the in-editor Assistant.
| Key | Purpose |
|---|---|
MASTRA_PLATFORM_ACCESS_TOKEN | Assistant platform token |
MASTRA_PROJECT_ID | Assistant project id |
Leave off unless your account team provided these.
Grafana / Prometheus monitoring
Ships metrics and logs to your own Grafana Cloud. Setting any of these credentials auto-enables the telemetry overlay (Alloy) on deploy.
| Keys |
|---|
GRAFANA_CLOUD_LOKI_USERNAME / GRAFANA_CLOUD_LOKI_PASSWORD |
GRAFANA_CLOUD_LOKI_URL |
GRAFANA_CLOUD_PROMETHEUS_USERNAME / GRAFANA_CLOUD_PROMETHEUS_PASSWORD |
GRAFANA_CLOUD_PROMETHEUS_URL |
TLS / HTTPS
Chosen at install time (--tls), or set later in .env.deploy + ftctl restart:
| Mode | Use case |
|---|---|
none | HTTP only — development / internal network |
self-signed | testing / internal with browser trust |
existing | production — provide your own --cert and --key |
Email (ACS)
Outbound email via Azure Communication Services is on by default:
| Key | Default |
|---|---|
ACS_EMAIL_ENABLED | true |
Networking
| Key | Default | Meaning |
|---|---|---|
NETWORK_MTU | 1431 | Docker network MTU — lower than 1500 to survive VPN/overlay encapsulation |
If flows to on-network databases hang or time out on a VPN'd host, an MTU
mismatch is the usual cause; 1431 is a safe default. Change it and
ftctl restart to re-create the network.
Execution capacity
| Key | Meaning |
|---|---|
RABBITMQ_PREFETCH | executions one worker runs at once |
MSSQL_POOL_MAX | connection-pool ceiling (keep ≥ RABBITMQ_PREFETCH) |
INSIGHTS_RETENTION_DAYS | how long execution telemetry is kept |
Size RABBITMQ_PREFETCH so it is ≥ your licensed concurrent-execution cap, so
the software licence — not a hardware shortfall — is what limits work. The pool
must cover it (RABBITMQ_PREFETCH ≤ MSSQL_POOL_MAX).
Secrets
Generated on the box and never transmitted. The critical one is
ENCRYPTION_KEY, which decrypts stored connection credentials. Back the
secrets up right after install — see Disaster Recovery.
Never change POSTGRES_PASSWORD / RABBITMQ_PASS / REDIS_PASSWORD after first
init — those services bake the password into their volume on first start.