Skip to content

Configuration reference

Every environment variable the controller API reads, grouped by area. Defaults shown are those set in code. Recorder-agent variables are documented separately in the recorder agent CLI reference.

DATABASE_URL is the master switch: unset → JSON/in-memory fallback stores (each with its own path below); set → Postgres via Drizzle.

Core / runtime

VariableDefaultPurpose
PORT8787API listen port.
NODE_ENVproduction enables strict behavior (a real admin password is required).
DATABASE_URLPostgres connection string. Unset → fallback stores.
RAKKR_WEB_ORIGINhttp://localhost:5173Allowed CORS / web origin.
RAKKR_RECORDING_CACHE_DIRdata/recordingsRoot directory for cached recording files.
RAKKR_RECORDING_CACHE_MAX_BYTES4294967296Max size of a single agent cache-file upload (4 GiB).
RAKKR_API_VERSION0.0.0-devController version reported by /healthz and status routes (stamped at image build).
RAKKR_API_NO_LISTEN1 skips binding a port (used by tests).
RAKKR_LISTEN_SESSION_TTL_SECONDS300Live-listen session TTL before eviction.
RAKKR_AUTH_FALLBACK_GRACE_MS900000How long the auth memory-fallback keeps honoring login-time permissions after the DB becomes unavailable (15 min).
RAKKR_SEED_DEMO_DATAenabledSet 0 to disable demo data seeding.
RAKKR_DEMO_METERSdisabled1 lets meter endpoints emit synthetic frames when no agent frame is stored (demonstration / screenshots / tests only). Off by default — real usage never fabricates meters; an absent feed reads as empty.
RAKKR_DEMO_METER_DBFSdBFS value for the synthetic demo meter data; only applies when RAKKR_DEMO_METERS=1.

Local admin & seeded access

VariableDefaultPurpose
RAKKR_LOCAL_ADMIN_EMAILadmin@rakkr.localLocal admin email.
RAKKR_LOCAL_ADMIN_NAMELocal AdminLocal admin display name.
RAKKR_LOCAL_ADMIN_PASSWORDrakkr-local-dev-password (dev only)Local admin password. Required when NODE_ENV=production — absence throws.
RAKKR_LOCAL_ADMIN_IDLocal admin user ID.
RAKKR_LOCAL_ADMIN_ROLEOverride local admin role(s).
RAKKR_LOCAL_ADMIN_GROUPSLocal admin group memberships.
RAKKR_LOCAL_RESOURCE_GRANTSJSON map of resource grants, e.g. {"node":["node_x32_test"]}.
RAKKR_LOCAL_ACCESS_POLICIESJSON array of seeded access policies.

OIDC / Azure AD

All disabled unless RAKKR_OIDC_ENABLED is truthy (1/on/true/yes).

VariableDefaultPurpose
RAKKR_OIDC_ENABLEDdisabledEnable OIDC login.
RAKKR_OIDC_ISSUERExplicit issuer URL (overrides tenant-derived issuer).
RAKKR_OIDC_AZURE_TENANT_IDAzure tenant; derives the issuer when RAKKR_OIDC_ISSUER is unset.
RAKKR_OIDC_CLIENT_IDOIDC client ID.
RAKKR_OIDC_CLIENT_SECRETOIDC client secret.
RAKKR_OIDC_REDIRECT_URICallback URI (must match the IdP app registration).
RAKKR_OIDC_SCOPESopenid profile emailRequested scopes.
RAKKR_OIDC_ALLOW_INSECURE_ISSUERDev/test only: permit HTTP OIDC discovery for a loopback issuer.

TLS / transport

If none of these are set, the API serves plain HTTP. See Transport security.

VariableDefaultPurpose
RAKKR_API_TLS_CERT_PATHActive server certificate (set with the key).
RAKKR_API_TLS_KEY_PATHActive server key (set with the cert).
RAKKR_API_TLS_CA_PATHCA bundle; also the client-CA fallback for mTLS.
RAKKR_API_TLS_NEXT_CERT_PATHNext (rotation) certificate.
RAKKR_API_TLS_NEXT_KEY_PATHNext (rotation) key.
RAKKR_API_TLS_NEXT_NOT_BEFOREnotBefore timestamp for the next cert summary.
RAKKR_API_TLS_CLIENT_CA_PATHClient-cert CA for mTLS (falls back to RAKKR_API_TLS_CA_PATH).
RAKKR_API_TLS_CLIENT_CERT_MODEoffmTLS mode: off / optional / required.

Node lifecycle / Ansible runner (controller side)

VariableDefaultPurpose
RAKKR_ANSIBLE_RUNNER_URLBase URL of the Ansible runner. Unset → lifecycle runs throw ansible_runner_unconfigured.
RAKKR_ANSIBLE_RUNNER_TOKENBearer token sent to the runner.
RAKKR_ANSIBLE_RUNNER_TIMEOUT_MS120000Runner request timeout.
RAKKR_NODE_LIFECYCLE_STORE_PATHdata/node-lifecycle-jobs.jsonJSON store for lifecycle jobs.

SSH users/keys/become-passwords (RAKKR_ANSIBLE_TARGETS, RAKKR_ANSIBLE_SSH_DIR, …) are read by the runner, not the controller — see Node lifecycle.

Node credentials & onboarding (controller side)

See Node onboarding.

VariableDefaultPurpose
RAKKR_NODE_SSH_MASTER_KEYfalls back to RAKKR_SECRET_KEYMaster key encrypting node SSH private keys at rest. Set in production; unset uses an insecure dev key.
RAKKR_RUNNER_TOKENShared token the Ansible runner presents to fetch per-node SSH keys/tokens (…/ssh-credential/material). Unset disables the runner fetch endpoint.

The runner side of the fetch (set on the runner, not the controller): RAKKR_RUNNER_CONTROLLER_URL, RAKKR_RUNNER_TOKEN, RAKKR_RUNNER_CONTROLLER_CA (self-signed CA bundle), RAKKR_RUNNER_ALLOW_INSECURE (1 skips TLS verify; dev only), RAKKR_RUNNER_CONTROLLER_TIMEOUT_SECONDS (default 20).

Recorder-agent update check

The controller polls GitHub releases so the nodes page can flag out-of-date recorder agents. See Node lifecycle.

VariableDefaultPurpose
RAKKR_AGENT_RELEASE_REPOyashau/RakkrGitHub repo polled for the latest agent-v… release.
RAKKR_GITHUB_TOKENOptional token to raise the GitHub API rate limit.
RAKKR_GITHUB_API_URLhttps://api.github.comGitHub API base URL.
RAKKR_AGENT_RELEASE_TTL_MS1800000Cache TTL for the release lookup (30 min).
RAKKR_AGENT_RELEASE_TIMEOUT_MS10000Per-request timeout for the release lookup.

JSON fallback store paths

Used when DATABASE_URL is unset; resolved relative to the working directory.

VariableDefault
RAKKR_RECORDING_METADATA_STORE_PATHdata/recordings-metadata.json
RAKKR_RECORDING_JOB_STORE_PATHdata/recording-jobs.json
RAKKR_SCHEDULE_STORE_PATHdata/schedules.json
RAKKR_RECORDING_PROFILE_STORE_PATHdata/recording-profiles.json
RAKKR_WATCHDOG_POLICY_STORE_PATHdata/watchdog-policies.json
RAKKR_CHANNEL_MAP_TEMPLATE_STORE_PATHdata/channel-map-templates.json
RAKKR_CHANNEL_MAP_ASSIGNMENT_STORE_PATHdata/channel-map-assignments.json
RAKKR_CHANNEL_MAP_ASSIGNMENT_PLAN_STORE_PATHdata/channel-map-assignment-plans.json
RAKKR_RETENTION_POLICY_STORE_PATHdata/retention-policies.json
RAKKR_UPLOAD_POLICY_STORE_PATHdata/upload-policies.json
RAKKR_UPLOAD_QUEUE_STORE_PATHdata/upload-queue.json
RAKKR_UPLOAD_DESTINATION_STORE_PATHdata/upload-destinations.json
RAKKR_CONTROLLER_SETTINGS_STORE_PATHdata/controller-settings.json
RAKKR_RECORDING_CHUNK_STORE_PATHdata/recording-chunks.json
RAKKR_ROOM_STORE_PATHdata/rooms.json
RAKKR_ROOM_ROSTER_STORE_PATHdata/room-roster.json
RAKKR_SWITCHER_STORE_PATHdata/switchers.json
RAKKR_SWITCHER_MAPPING_STORE_PATHdata/switcher-mappings.json

Background runners & leases

VariableDefaultPurpose
RAKKR_SCHEDULE_RUNNER_ENABLEDenabledSet 0 to disable the schedule runner.
RAKKR_SCHEDULE_RUNNER_INTERVAL_SECONDS30Schedule runner tick.
RAKKR_SCHEDULE_FAILURE_RETRY_SECONDS300Retry delay after a schedule failure.
RAKKR_UPLOAD_RUNNER_ENABLEDenabledSet 0 to disable the upload runner.
RAKKR_UPLOAD_RUNNER_INTERVAL_SECONDS60Upload runner tick.
RAKKR_UPLOAD_RUNNER_BATCH_SIZE10Items per upload pass.
RAKKR_UPLOAD_QUEUE_LEASE_SECONDS900Upload queue item lease.
RAKKR_UPLOAD_QUEUE_MAX_ATTEMPTS5Max attempts per queue item.
RAKKR_RETENTION_RUNNER_ENABLEDenabledSet 0 to disable the retention runner.
RAKKR_RETENTION_RUNNER_INTERVAL_SECONDS300Retention runner tick.
RAKKR_RETENTION_RUNNER_BATCH_SIZE25Items per retention pass.
RAKKR_RECORDING_JOB_LEASE_RUNNER_ENABLEDenabledSet 0 to disable the job-lease runner.
RAKKR_RECORDING_JOB_LEASE_RUNNER_INTERVAL_SECONDS10Lease runner tick.
RAKKR_RECORDING_JOB_LEASE_SECONDS30Recording-job lease duration.
RAKKR_WATCHDOG_RUNNER_ENABLEDenabledSet 0 to disable the watchdog runner.
RAKKR_WATCHDOG_RUNNER_INTERVAL_SECONDS30Watchdog runner tick.
RAKKR_WATCHDOG_MAX_SAMPLE_SPAN_SECONDS30Watchdog max sample span.
RAKKR_WATCHDOG_METER_MAX_AGE_SECONDSWatchdog meter freshness cutoff.
RAKKR_NODE_OFFLINE_AFTER_SECONDS120Heartbeat staleness before a node is offline (0 disables).
RAKKR_METER_HISTORY_LIMIT600In-memory meter-frame history cap.
RAKKR_SWITCHER_ROUTING_RUNNER_ENABLEDenabledSet 0 to disable the switcher routing runner.
RAKKR_SWITCHER_ROUTING_RUNNER_INTERVAL_SECONDS20Switcher routing runner tick.

Audio tooling & recording-job defaults

VariableDefaultPurpose
RAKKR_AUDIO_PREVIEW_MAX_BYTES67108864Max decoded audio preview size (64 MiB).
RAKKR_AUDIO_TOOL_TIMEOUT_MS15000ffmpeg/ffprobe invocation timeout.
RAKKR_FFMPEG_COMMAND / RAKKR_FFPROBE_COMMANDffmpeg / ffprobeOverride the audio tool binaries.
RAKKR_FFMPEG_ARGS_PREFIX / RAKKR_FFPROBE_ARGS_PREFIXExtra args before the tool args.
RAKKR_AGENT_CAPTURE_CHANNELS2Default capture channel count for jobs.
RAKKR_AGENT_CAPTURE_DEVICEdefaultDefault capture device for jobs.
RAKKR_AGENT_CAPTURE_FORMATS16_LEDefault capture sample format for jobs.
RAKKR_AGENT_CAPTURE_SAMPLE_RATE48000Default capture sample rate for jobs.
RAKKR_AGENT_CAPTURE_SECONDS3600Default capture duration for jobs.
RAKKR_AGENT_CAPTURE_INTERFACE_IDDefault capture interface for job targets.

Upload destination credentials

All upload-destination connection details are configured in Settings → Upload Destinations and stored by the controller — there are no RAKKR_-prefixed S3 variables and no AWS_* environment dependency. Many named destinations of each kind may exist; an upload policy references one by id.

  • S3 is configured per destination: a provider preset (AWS, Cloudflare R2, Backblaze B2, Wasabi, MinIO, DigitalOcean Spaces, custom), region and/or custom endpoint, bucket, upload path/prefix, access key, secret key, and path-style. Uploads go directly to the configured endpoint.
  • SMB is configured per destination: server, share, domain, username, password, upload path, and port. The controller speaks SMB 2.1/3.x directly over the network — no OS mount is required.
  • SMB passwords and S3 secret access keys are encrypted at rest with AES-256-GCM.
VariableDefaultPurpose
RAKKR_SECRET_KEYdev fallback (insecure)Master key used to encrypt/decrypt upload-destination secrets at rest. Set this in production; if unset, an insecure development key is used and a warning is logged. Rotating it makes previously stored secrets undecryptable (re-enter them).
RAKKR_REQUIRE_SECRET_KEYWhen set, refuses the insecure dev fallback key (requires a real RAKKR_SECRET_KEY).

Test-only

VariablePurpose
RAKKR_API_NO_LISTEN1 skips port binding (set by the test runner).
RAKKR_API_TEST_DATABASE_URLIf set, the test runner copies it into DATABASE_URL; otherwise DATABASE_URL is removed so tests use fallback stores.
RAKKR_SEED_DEMO_DATA=0Disables demo seeding during tests.