diff --git a/frontend/Dockerfile.railway b/frontend/Dockerfile.railway index 818bfc2c..c7e06ea4 100644 --- a/frontend/Dockerfile.railway +++ b/frontend/Dockerfile.railway @@ -16,13 +16,16 @@ RUN pnpm install --frozen-lockfile # Rebuild the source code only when needed FROM base AS builder WORKDIR /app -COPY --from=deps /app/node_modules ./node_modules -COPY frontend . # Enable pnpm RUN corepack enable && corepack prepare pnpm@latest --activate +COPY --from=deps /app/node_modules ./node_modules +COPY frontend . +# Accept BACKEND_URL as build argument +ARG BACKEND_URL +ENV BACKEND_URL=${BACKEND_URL} # Build Next.js app RUN pnpm run build