# Development environment configuration VITE_BACKEND_URL=http://localhost:9621 VITE_API_PROXY=true VITE_API_ENDPOINTS=/api,/documents,/graphs,/graph,/health,/query,/docs,/redoc,/openapi.json,/login,/auth-status,/static # LightRAG WebUI — build-time configuration template. # # Primary use case: hosting multiple LightRAG instances on one host behind a # reverse proxy that routes by site prefix: # https://host/site01/webui/ → WebUI for instance #1 # https://host/site02/webui/ → WebUI for instance #2 # Each site needs its OWN WebUI build with its own prefix values, because # Vite STATICALLY REPLACES these into the bundle at build time. There is no # runtime override yet — see the project root `env.example` for the matching # backend variables (LIGHTRAG_API_PREFIX / LIGHTRAG_WEBUI_PATH). # # How to use: # - Copy to `.env` (always loaded) or `.env.production` (only loaded for # `bun run build`), or pass on the command line: # VITE_API_PREFIX=/site01 VITE_WEBUI_PREFIX=/site01/webui/ bun run build # - Build output goes to `../lightrag/api/webui/`. To produce one bundle per # site, build once per site and stash the output (e.g. into a per-site # container image or a per-site directory mounted by the server). # Browser-visible URL prefix used as `axios.baseURL`, in `fetch()` template # strings, and as the iframe `src` for the API docs page. # # Must equal the backend `LIGHTRAG_API_PREFIX` for the same site (the prefix # the reverse proxy strips before forwarding to FastAPI). Empty / "/" → no # prefix (single-instance / no reverse-proxy deployment). # # Example for site01: VITE_API_PREFIX=/site01 # VITE_API_PREFIX=/site01 # Browser-visible URL prefix where the WebUI itself is served. Used as # Vite's `base` option (asset URL prefix in index.html) and by `` links. # # Must equal LIGHTRAG_API_PREFIX + LIGHTRAG_WEBUI_PATH + "/" — i.e. the FULL # path the user's browser sees, including any reverse-proxy prefix in front # of the in-app mount path. Trailing "/" is required by Vite; the # normalization helper enforces it automatically. # # Example for site01 (WebUI at https://host/site01/webui/): # VITE_WEBUI_PREFIX=/site01/webui/ # VITE_WEBUI_PREFIX=/site01/webui/