Skip to main content

Environment variables

The daemon is configured in config.toml (Configuration). The other services read environment variables from their env files.

Controller (/etc/default/machina-platform)​

VariableDefaultPurpose
DATABASE_URLsqlite:///var/lib/machina/controller.dbEmbedded SQLite state; no external database
NATS_URLunsetOptional NATS task fan-out across controller instances
MACHINA_CONTROLLER_IDrandom ctrl-xxxxxxxx per startStable instance id; set it on every instance in a multi-controller deployment
MACHINA_AGENT_ADDRhttp://127.0.0.1:50051Agent gRPC address
MACHINA_AGENT_CA, MACHINA_AGENT_CLIENT_CERT, MACHINA_AGENT_CLIENT_KEYunsetmTLS to agents
MACHINA_WITNESS_URLS, MACHINA_WITNESS_MODEunset, anyComma-separated witness URLs (at most 5) HA must reach before it fences or recovers; mode any or majority
MACHINA_K3S_FLEETunset1 enables the fleet k3s cluster API (/api/v1/k8s-clusters); hosts must also opt in with MACHINA_AGENT_K3S_ENABLED=1
MACHINA_JWT_SECRETrandom per processJWT signing secret; set it for sessions that survive restarts
MACHINA_ALLOW_DEV_SECRETSunsetAllow the well-known development secret (never in production)
MACHINA_API_KEY_MASTER_KEYunset64-hex-char AES-256-GCM key for stored LLM provider and BMC secrets (openssl rand -hex 32)
MACHINA_API_KEY_MASTER_KEY_FILEunsetPath to a root-readable file holding that key; read first, so the key stays out of the environment
MACHINA_JWT_PREVIOUS_SECRETSunsetComma-separated earlier signing secrets, accepted for verification only (rollover)
MACHINA_SECURITY_PROFILEdevelopmentproduction enables the strict preflight (Production hardening)
MACHINA_AUDIT_RETENTION_DAYS365Days of audit_logs kept; clamped to 7-3650, 0 keeps everything
MACHINA_BPF_REQUIREDunset (set true by the packaged bpfd unit)bpfd refuses to start without its embedded eBPF object
MACHINA_TRANSIVA_URL, MACHINA_TRANSIVA_API_KEY, MACHINA_TRANSIVA_TIMEOUT_SECShttp://127.0.0.1:5070, unset, 60Transiva migration gateway
MACHINA_PUBLIC_URLhttp://127.0.0.1:5093Public controller URL
MACHINA_WEB_URLhttp://127.0.0.1:5173Web UI URL used in links
MACHINA_DAEMON_URL—How the controller reaches the daemon
MACHINA_FENCE_COMMANDunsetFallback fence command run by the agent ({hostname} is substituted)
MACHINA_BPF_ENFORCE_LEASE_SECS900Default eBPF enforcement lease
MACHINA_RATE_LIMIT_ENABLED, MACHINA_RATE_LIMIT_PER_MIN—API rate limiting
MACHINA_SMTP_HOST, _PORT, _USER, _PASS, _FROMunsetEmail notifications
MACHINA_AI_DISABLEDunsetTurn off Zyra AI
MACHINA_SKIP_AUTHunsetDisable auth (development only)
GUESTKIT_ENABLEDtrueGuestKit features
ATLAS_ENABLED, ATLAS_BASE_URL, ATLAS_TOKEN, …offAtlas storage (Integrations)

Agent​

VariableDefaultPurpose
MACHINA_LIBVIRT_URIqemu:///systemlibvirt connection
MACHINA_AGENT_TLS_CERT, MACHINA_AGENT_TLS_KEYunsetAgent TLS certificate
MACHINA_AGENT_TOKENunsetShared token between controller and agent
MACHINA_AGENT_K3S_ENABLEDunset1 lets the controller install, upgrade and remove k3s on this host (runs root installers)
MACHINA_BPFD_SOCK/run/machina-bpf/bpfd.sockWhere to reach machina-bpfd
MACHINA_FLUXVM_URLthe host's [fluxvm] base_url when enabledfluxvm-api the controller manages FluxVM VMs through
MACHINA_FLUXVM_TOKEN[fluxvm] tokenBearer token for it
MACHINA_FLUXVM_INSECURE_TLS[fluxvm] insecure_tls1 accepts a self-signed fluxvm-api

eBPF (/etc/default/machina-bpfd)​

VariableDefaultPurpose
MACHINA_BPFD_SOCK/run/machina-bpf/bpfd.sockControl socket
MACHINA_BPFD_STATE_DIR/var/lib/machina/bpfPersisted accounting
MACHINA_BPFD_SOCKET_GROUPempty (socket 0600)Group allowed to use the socket
MACHINA_BPF_ENFORCE_LEASE_SECS900Enforcement lease length
MACHINA_BPF_SOCKOPS_CGROUP/sys/fs/cgroupcgroup for TCP connect timing
MACHINA_BPF_TLSFP_CGROUP/sys/fs/cgroupcgroup for TLS fingerprints
MACHINA_BPF_L7S_CGROUP/sys/fs/cgroupcgroup for sampled L7
MACHINA_BPF_XDP_SKBunsetForce generic (SKB) XDP mode
MACHINA_SCX_BINnext to machina-bpfdmachina-scx helper path

Kubernetes CNI​

See Kubernetes CNI for MACHINA_CNI_*.

Bare metal​

The bare-metal provisioning variables (MACHINA_BMC_*, MACHINA_METAL_*, MACHINA_IPMITOOL) are listed with their defaults in Bare-metal API and CLI.