With NODE_ENV=production set, npm ci skips devDependencies - but
npm run build (vinxi/vite under the hood) needs them, failing with
ERR_MODULE_NOT_FOUND for 'vite'. This broke every build regardless
of what changed in the app itself, including the innocuous waitlist
page added in 26667c7. Pre-existing bug, not introduced by that
commit - confirmed via git log that the NODE_ENV=production line
predates it.
Moved NODE_ENV=production to the runtime stage only, where it
actually matters (affects the running server, not the build tooling).
Added --include=dev to npm ci for defense in depth if NODE_ENV ever
gets reintroduced in the builder stage.
Verified with a local - completes
successfully now.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Server-side gateway proxy (login, forgot-password, reset-password, all
/api/admin/* and /api/gateway/* calls) was reading import.meta.env.VITE_GATEWAY_URL,
which Vite only inlines at build time. The Dockerfile wrote GATEWAY_URL (no VITE_
prefix, and localhost besides) to .env at build time, so the var was never picked
up and the fallback http://localhost:9100 got baked into the server bundle
permanently — unreachable inside the pod, causing every admin auth call to 502
regardless of the correct GATEWAY_URL already set in the k8s ConfigMap.
Switch to process.env.GATEWAY_URL, read at runtime like the rest of the server
config already is.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
- Change FROM node:20-alpine to FROM registry.nxtgauge.com/node:20-alpine
- Update both Dockerfile and Dockerfile.simple
- Fixes Docker Hub rate limiting errors in Woodpecker builds