From 2d56c07eaee69cbc0e2209dfb934f116886f3b99 Mon Sep 17 00:00:00 2001 From: admin Date: Fri, 20 Mar 2026 16:59:10 +0700 Subject: [PATCH] 260320:1659 Refactor Overrall #09 Fix by antigravity: pnpm frontend deploy --- frontend/lib/auth.ts | 2 +- .../04-00-docker-compose/docker-compose-app.yml | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/frontend/lib/auth.ts b/frontend/lib/auth.ts index bb89353..d0efdde 100644 --- a/frontend/lib/auth.ts +++ b/frontend/lib/auth.ts @@ -11,7 +11,7 @@ const loginSchema = z.object({ password: z.string().min(1), }); -const baseUrl = process.env.NEXT_PUBLIC_API_URL || "http://localhost:3001/api"; +const baseUrl = (typeof window === "undefined" ? process.env.INTERNAL_API_URL : null) || process.env.NEXT_PUBLIC_API_URL || "http://localhost:3001/api"; // Helper to parse JWT expiry function getJwtExpiry(token: string): number { diff --git a/specs/04-Infrastructure-OPS/04-00-docker-compose/docker-compose-app.yml b/specs/04-Infrastructure-OPS/04-00-docker-compose/docker-compose-app.yml index d4289b2..9d3a75f 100644 --- a/specs/04-Infrastructure-OPS/04-00-docker-compose/docker-compose-app.yml +++ b/specs/04-Infrastructure-OPS/04-00-docker-compose/docker-compose-app.yml @@ -119,6 +119,8 @@ services: # --- NextAuth --- AUTH_SECRET: 'eebc122aa65adde8c76c6a0847d9649b2b67a06db1504693e6c912e51499b76e' AUTH_URL: 'https://lcbp3.np-dms.work' + AUTH_TRUST_HOST: 'true' + INTERNAL_API_URL: 'http://backend:3000/api' networks: - lcbp3 healthcheck: