docs(configuration): document the real frontend API base variables (#5829)

The frontend environment table listed NEXT_PUBLIC_API_URL, which no code reads: the validated client schema in frontend/src/env.js only accepts NEXT_PUBLIC_BACKEND_BASE_URL, NEXT_PUBLIC_LANGGRAPH_BASE_URL, and NEXT_PUBLIC_STATIC_WEBSITE_ONLY, and frontend/src/core/config/index.ts builds the API base URL from the first two. Following the old row silently did nothing. Replace it with the two variables that actually override the Gateway and LangGraph base URLs.
This commit is contained in:
kbkb628 2026-09-24 18:09:12 +08:00 committed by GitHub
parent 509151d006
commit ae1edfdc8b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -276,12 +276,13 @@ Docker startup sequence.
Set these before running `pnpm build` or starting the frontend in production:
| Variable | Required | Description |
| --------------------- | -------------------------- | ---------------------------------------------------------------- |
| `BETTER_AUTH_SECRET` | **Required** in production | Secret for session signing. Use `openssl rand -base64 32`. |
| `BETTER_AUTH_URL` | Recommended | Public-facing base URL (e.g., `https://your-domain.com`) |
| `SKIP_ENV_VALIDATION` | Optional | Set to `1` to skip env validation during build (not recommended) |
| `NEXT_PUBLIC_API_URL` | Optional | Override the API base URL for the frontend |
| Variable | Required | Description |
| -------------------------------- | -------------------------- | ----------------------------------------------------------------- |
| `BETTER_AUTH_SECRET` | **Required** in production | Secret for session signing. Use `openssl rand -base64 32`. |
| `BETTER_AUTH_URL` | Recommended | Public-facing base URL (e.g., `https://your-domain.com`) |
| `SKIP_ENV_VALIDATION` | Optional | Set to `1` to skip env validation during build (not recommended) |
| `NEXT_PUBLIC_BACKEND_BASE_URL` | Optional | Override the Gateway base URL used for REST and SSR calls |
| `NEXT_PUBLIC_LANGGRAPH_BASE_URL` | Optional | Override the LangGraph API base URL (defaults to `<backend>/api`) |
In development, set these in a `.env` file at the repo root: