Skip to content

Environment Variables

Copy this block into .env (or paste directly into Coolify’s Developer View / Dokploy’s Environment tab) and fill in the placeholders. Generate KOVA_ENCRYPTION_KEY with openssl rand -hex 32.

.env
# Exact public origin in your browser (scheme + host + port)
KOVA_BASE_URL=https://kova.example.com
# Required: 32-byte key (64 hex chars or base64) for AES-256-GCM S3 credential encryption
KOVA_ENCRYPTION_KEY=<generated-64-hex-key>
# Recommended on public hosts (skips unauthenticated /setup when zero users exist; 12+ char password):
KOVA_ADMIN_EMAIL=you@example.com
KOVA_ADMIN_PASSWORD=<strong-12+-char-password>
# Reverse proxy IP only (single /32, never a broad network range):
# KOVA_TRUSTED_PROXIES=172.30.0.10/32
# KOVA_CLIENT_IP_HEADER=cf-connecting-ip
# Set true if connecting to local/LAN MinIO, Garage, or RustFS:
# KOVA_ALLOW_PRIVATE_ENDPOINTS=true

Keep .env at mode 600 (chmod 600 .env) and never commit it to Git. Store a backup of KOVA_ENCRYPTION_KEY separately from /data.

Variable Required Default Purpose
KOVA_ENCRYPTION_KEY Yes — 32-byte hex or base64 key for AES-256-GCM encryption of saved S3 credentials.
KOVA_ENCRYPTION_KEY_PREVIOUS No — Previous key for zero-downtime key rotation (bun apps/server/dist/crypto/reencrypt-cli.js in Docker, or bun run cli:reencrypt locally).
KOVA_BASE_URL Recommended http://localhost:3000 Public origin for cookies, Passkeys RP ID, OIDC callbacks, and /s/:token links.
KOVA_PORT No 3000 HTTP port bound by Kova.
KOVA_DB_PATH No /data/kova.db Local SQLite database path (WAL mode enabled automatically; ./data/kova.db outside Docker).
KOVA_TURSO_URL / KOVA_TURSO_AUTH_TOKEN No — Optional remote libSQL/Turso database connection.
KOVA_TRUSTED_PROXIES No (none) Reverse proxy /32 IP(s) or hop count (local peers). Never set broad subnets like 10.0.0.0/8.
KOVA_CLIENT_IP_HEADER No x-forwarded-for Forwarded client-IP header (x-forwarded-for or cf-connecting-ip behind Cloudflare).
KOVA_ALLOW_PRIVATE_ENDPOINTS No false Allow connections to loopback/RFC1918 endpoints (local MinIO, Garage, RustFS).
KOVA_ADMIN_EMAIL / KOVA_ADMIN_PASSWORD No — Headless first-run Admin seed when zero users exist (recommended on public hosts).
KOVA_MAX_UPLOAD_CONCURRENCY No 4 Default concurrent presigned part uploads per multipart transfer (1–16).
KOVA_OIDC_ISSUER / CLIENT_ID / CLIENT_SECRET No — Optional OIDC/SSO login (Authentik, Authelia, Pocket ID, Keycloak, Okta).
KOVA_OIDC_NAME No OIDC / SSO Button label shown on the login screen when OIDC is enabled.
KOVA_OIDC_AUTO_PROVISION No false Auto-creates new OIDC users as Member with zero bucket scopes when true.
KOVA_OIDC_ALLOW_IMPLICIT_LINKING No false Allow OIDC sign-in to implicitly link to pre-existing password accounts by email.