fix(frontend): add AUTH_URL + AUTH_SECRET build ARGs for NextAuth v5
Deploy to Production / test (push) Has been cancelled
Deploy to Production / deploy (push) Has been cancelled

This commit is contained in:
Patrick Plate
2026-06-13 09:30:13 +02:00
parent d650987b9a
commit 805bc4f00d
+6 -1
View File
@@ -13,12 +13,17 @@ COPY . .
ENV NEXT_TELEMETRY_DISABLED=1
# Provide placeholder build-time values so Next.js SSG doesn't crash on undefined URLs
# Real values are injected at runtime via docker-compose environment:
# Real values are injected at runtime via docker-compose environment.
# NextAuth v5 uses AUTH_URL (not NEXTAUTH_URL) as its canonical base URL.
ARG NEXTAUTH_URL=http://localhost:3000
ARG AUTH_URL=http://localhost:3000
ARG NEXTAUTH_SECRET=build-time-placeholder-secret-minimum-32-chars
ARG AUTH_SECRET=build-time-placeholder-secret-minimum-32-chars
ARG BACKEND_URL=http://localhost:8080
ENV NEXTAUTH_URL=${NEXTAUTH_URL}
ENV AUTH_URL=${AUTH_URL}
ENV NEXTAUTH_SECRET=${NEXTAUTH_SECRET}
ENV AUTH_SECRET=${AUTH_SECRET}
ENV BACKEND_URL=${BACKEND_URL}
RUN pnpm build