Skip to main content
Version: v3.8.0

Controller configuration

The Controller reads a YAML file (default config.yaml in the image). Set CONFIG_PATH to mount a custom file. Environment variables override YAML keys at runtime (containers, Helm, systemd).

Greenfield database

Controller v3.8.0 ships a new schema. There is no v3.7 → v3.8 database migrator. Install with an empty SQLite file or a new MySQL/PostgreSQL database. See Migrating to v3.8.0.

Main YAML sections

app:
name: iofog
controlPlane: Remote # Remote | Kubernetes | Local
namespace: iofog

server:
port: 51121
publicUrl: "https://controller.example.com:51121" # CONTROLLER_PUBLIC_URL
trustProxy: false # TRUST_PROXY
# tls:
# path:
# key: ""
# cert: ""
# intermediateCert: ""

console:
port: 8008
url: "https://console.example.com:8008" # CONSOLE_URL

auth:
mode: embedded # embedded | external - AUTH_MODE
insecureAllowHttp: false
bootstrap:
username: "" # OIDC_BOOTSTRAP_ADMIN_USERNAME (embedded first boot)
password: "" # OIDC_BOOTSTRAP_ADMIN_PASSWORD
# issuerUrl: "" # OIDC_ISSUER_URL - required in external mode
# client:
# id: "" # OIDC_CLIENT_ID
# secret: "" # OIDC_CLIENT_SECRET
# consoleClient: "" # OIDC_CONSOLE_CLIENT_ID

database:
provider: sqlite # sqlite | mysql | postgres
sqlite:
databaseName: controller_db.sqlite
pragmas:
journalMode: WAL
busyTimeoutMs: 10000

nats:
enabled: true

systemImages:
router:
"1": "<router-image-amd64>"
"2": "<router-image-arm64>"
# keys 3–4: riscv64, arm - see defaults in Controller config.yaml
debug:
"1": "<debugger-image>"
nats:
"1": "<nats-image>"

Default image refs use your build flavor registry (ghcr.io/datasance). Override per arch with ROUTER_IMAGE_1ROUTER_IMAGE_4, NATS_IMAGE_*, and DEBUG_IMAGE_* env vars.

v3.8 renames in config

Removed (v3.7)v3.8
viewer.port, viewer.urlconsole.port, console.url
server.ssl.*server.tls.*
auth.realm, auth.url, KC_*auth.mode, OIDC_*, AUTH_*
diagnostics sectionRemoved (diagnostics APIs removed)

EdgeOps Console reads consoleUrl from runtime controller-config.js (not viewerUrl). Details: EdgeOps Console configuration.

Authentication and Console environment variables

These variables are the primary knobs for auth and Console wiring. Full auth setup: Embedded OIDC (default) and External OIDC (optional appendix).

Environment variableConfig keyDescription
AUTH_MODEauth.modeembedded (default) or external
OIDC_ISSUER_URLauth.issuerUrlFull issuer URL. Required in external mode. In embedded mode the issuer is {CONTROLLER_PUBLIC_URL}/oidc
OIDC_CLIENT_IDauth.client.idOAuth client for Controller API / BFF
OIDC_CLIENT_SECRETauth.client.secretClient secret
OIDC_CONSOLE_CLIENT_IDauth.consoleClientEdgeOps Console SPA client ID
AUTH_CONSOLE_CLIENT_ENABLEDauth.consoleClient.enabledEnable Console OAuth client
OIDC_BOOTSTRAP_ADMIN_USERNAMEauth.bootstrap.usernameFirst admin user (embedded first boot)
OIDC_BOOTSTRAP_ADMIN_PASSWORDauth.bootstrap.passwordBootstrap admin password
AUTH_INSECURE_ALLOW_HTTPauth.insecureAllowHttpAllow http:// in CONTROLLER_PUBLIC_URL (dev only)
AUTH_SESSION_STORE_TYPEauth.sessionStore.typememory or database (HA BFF sessions)
AUTH_SESSION_SECRETauth.sessionStore.secretBFF session encryption secret
CONSOLE_PORTconsole.portEdgeOps Console listen port (default 8008)
CONSOLE_URLconsole.urlPublic Console URL for OAuth redirects

TLS environment variables

v3.8 renamed SSL_* to TLS_*. Listener certificates are also used for agent trust (caCert on provision) and embedded OAuth token exchange.

Environment variableConfig keyDescription
TLS_PATH_KEYserver.tls.path.keyPath to TLS private key
TLS_PATH_CERTserver.tls.path.certPath to TLS certificate
TLS_PATH_INTERMEDIATE_CERTserver.tls.path.intermediateCertIntermediate / chain certificate
TLS_BASE64_KEYserver.tls.base64.keyBase64-encoded key (alternative to path)
TLS_BASE64_CERTserver.tls.base64.certBase64-encoded certificate
TLS_BASE64_INTERMEDIATE_CERTserver.tls.base64.intermediateCertBase64-encoded intermediate cert
CONTROLLER_PUBLIC_URLserver.publicUrlCanonical external HTTPS URL (required for embedded OAuth)
TRUST_PROXYserver.trustProxyHonor X-Forwarded-* behind reverse proxy

Other common environment variables

Environment variableConfig keyDescription
CONFIG_PATH-Path to YAML config file
SERVER_PORTserver.portREST API port (default 51121)
SERVER_DEV_MODEserver.devModeDeveloper mode
CONTROLLER_NAMESPACEapp.namespaceKubernetes / RBAC namespace
CONTROL_PLANEapp.controlPlaneRemote, Kubernetes, or Local
DB_PROVIDERdatabase.providersqlite, mysql, or postgres
DB_HOST, DB_PORT, DB_USERNAME, DB_PASSWORD, DB_NAMEdatabase.*Provider-specific connection
DB_USE_SSL, DB_SSL_CAdatabase.*.useSSL, sslCADatabase TLS
NATS_ENABLEDnats.enabledPlatform NATS relay and hub features
LOG_LEVELlog.levelLog level
WS_EXEC_MAX_CONCURRENT_PER_RESOURCEserver.webSocket.session.execMaxConcurrentPerResourceExec sessions per microservice (default 5)

Boolean env vars (TRUST_PROXY, SERVER_DEV_MODE, DB_USE_SSL, NATS_ENABLED, and others) accept true/false or 1/0 from Kubernetes string values.

The full mapping lives in the Controller repo: src/config/env-mapping.js.

Control plane deployment

When you deploy with potctl or the Operator, many values come from Control Plane YAML (auth, database, controller blocks) instead of hand-editing config.yaml. See Control Plane YAML and Platform Deployment.

Group 3See anything wrong with the document? Help us improve it!