# ────────────────────────────────────────────────────────────────────── # OmniRoute — Self-Host env (minimal, zero-fee self-host) # ────────────────────────────────────────────────────────────────────── # cp .env.selfhost.example .env # Edit only the two lines marked `# EDIT ME`. Everything else has a sane # default. No secrets are baked in — OmniRoute never ships credentials. # # Full variable reference: docs/guides/DOCKER_GUIDE.md and .env.example # ────────────────────────────────────────────────────────────────────── # ── Ports (host-side) ────────────────────────────────────────────────── # Dashboard + API + Live-WS. Already match the image defaults. DASHBOARD_PORT=20128 API_PORT=20129 LIVE_WS_PORT=20132 # ── Bind address ─────────────────────────────────────────────────────── # 127.0.0.1 = loopback only (safe with REQUIRE_API_KEY=false, the default). # Set to 0.0.0.0 ONLY when REQUIRE_API_KEY=true OR a reverse proxy # enforces auth upstream. Exposing an unauthenticated /v1 proxy on the # LAN/WAN lets anyone burn your provider quotas. # EDIT ME if you must. APP_BIND_HOST=127.0.0.1 # ── Auth ────────────────────────────────────────────────────────────── # false = the dashboard and /v1 proxy are open to APP_BIND_HOST's network. # true = every request needs an API key / dashboard login. The dashboard # auto-creates INITIAL_PASSWORD on first boot (read it from the logs: # `docker logs omniroute | grep -i password`). # EDIT ME — set true. REQUIRE_API_KEY=false # INITIAL_PASSWORD= # uncomment to pre-seed the dashboard password # ── Memory ceiling (V8 old-space) ────────────────────────────────────── # 1024 = dashboard + light chat. Coding agents (long POST /v1/responses # bodies) need more — see SELF_HOST_GUIDE.md "sizing". 2048 is a safe # default for a single user who runs Claude Code / Codex through it. OMNIROUTE_MEMORY_MB=2048 # ── Browser-facing origin (optional) ─────────────────────────────────── # Set ONLY if you expose OmniRoute behind a domain via a reverse proxy. # NEXT_PUBLIC_BASE_URL=https://your-domain.example.com # BASE_URL=http://omniroute:20128