diff --git a/frontend/Dockerfile b/frontend/Dockerfile index ed39f80..a5cbc29 100644 --- a/frontend/Dockerfile +++ b/frontend/Dockerfile @@ -24,6 +24,12 @@ RUN npm ci COPY . . ENV ASTRO_TELEMETRY_DISABLED=1 + +# PUBLIC_API_URL must be set at build time for Vite to inline it. +# Empty string = same-origin (Caddy routes /api/* to backend). +ARG PUBLIC_API_URL="" +ENV PUBLIC_API_URL=${PUBLIC_API_URL} + RUN npm run build