Skip to main content
Unkey services read configuration from a TOML file passed at startup. Environment variables can be referenced with ${VAR} and are expanded before parsing. Defaults and validation run after parsing. The config schema maps to svc/ctrl/worker/config.go. The control plane worker is configured via a TOML file: control-worker --config=unkey.toml.

Configuration model

The control plane worker loads configuration from a TOML file using config.Load. Defaults and validation are applied after parsing. Runtime-only values (for example Clock) cannot be set in the file.

Required settings

These fields must be set for production deployments.

Optional settings

ACME configuration

ACME settings live under acme. Enable Route53 DNS-01 challenges with acme.route53.

Restate configuration

Build and registry configuration

build.backend selects how builds run. The default depot backend runs builds on Depot.dev and is what production uses. Builds are enabled when registry.password is set. In that case, registry.repository, registry.username, build.depot.api_url, and build.depot.project_region must also be set. The kubernetes backend runs each build as a one-off BuildKit Job in the cluster the worker runs in. It needs no Depot account, but the build pods run privileged without further isolation, so it is intended for local development only. It requires registry.repository and in-cluster credentials with permission to manage Jobs and read Pods in the configured namespace. The worker accepts the legacy top-level [depot] table during migration. New configurations should use [build.depot].

ClickHouse configuration

GitHub configuration

GitHub configuration is optional and can be omitted for local development.

Heartbeat and Slack

Example