mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-26 18:42:49 +00:00
Update environment variable names for passenger web apps in Docker configuration
This commit is contained in:
@@ -60,7 +60,7 @@ services:
|
||||
args:
|
||||
TURBO_FILTER: "@edr/passenger-portal"
|
||||
APP_PATH: apps/edr-passenger-web/portal
|
||||
VITE_API_URL: ${PASSENGER_VITE_API_URL:-http://localhost:4000}
|
||||
NEXT_PUBLIC_API_URL: ${PASSENGER_API_URL:-http://localhost:4000}
|
||||
secrets:
|
||||
- npmrc
|
||||
ports:
|
||||
@@ -73,7 +73,7 @@ services:
|
||||
args:
|
||||
TURBO_FILTER: "@edr/passenger-backoffice"
|
||||
APP_PATH: apps/edr-passenger-web/backoffice
|
||||
VITE_API_URL: ${PASSENGER_VITE_API_URL:-http://localhost:4000}
|
||||
NEXT_PUBLIC_API_URL: ${PASSENGER_API_URL:-http://localhost:4000}
|
||||
secrets:
|
||||
- npmrc
|
||||
ports:
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
ARG TURBO_FILTER=@edr/freight-portal
|
||||
ARG APP_PATH=apps/edr-freight-web/portal
|
||||
ARG VITE_API_URL=http://localhost:3001/api
|
||||
ARG NEXT_PUBLIC_API_URL=http://localhost:4000
|
||||
|
||||
FROM node:24.15.0-alpine AS base
|
||||
RUN apk add --no-cache libc6-compat
|
||||
@@ -25,7 +26,9 @@ FROM base AS builder
|
||||
ARG TURBO_FILTER
|
||||
ARG APP_PATH
|
||||
ARG VITE_API_URL
|
||||
ARG NEXT_PUBLIC_API_URL
|
||||
ENV VITE_API_URL=${VITE_API_URL}
|
||||
ENV NEXT_PUBLIC_API_URL=${NEXT_PUBLIC_API_URL}
|
||||
COPY --from=installer /app/ .
|
||||
COPY --from=pruner /app/out/full/ .
|
||||
|
||||
@@ -41,8 +44,8 @@ RUN NODE_OPTIONS="--max-old-space-size=4096" pnpm turbo build --filter="${TURBO_
|
||||
exit 1)
|
||||
|
||||
# Verify build output exists before proceeding
|
||||
RUN if [ ! -d "/app/${APP_PATH}/dist" ]; then \
|
||||
echo "ERROR: Build output directory not found at /app/${APP_PATH}/dist"; \
|
||||
RUN if [ ! -d "/app/${APP_PATH}/dist" ] && [ ! -d "/app/${APP_PATH}/out" ]; then \
|
||||
echo "ERROR: Build output directory not found at /app/${APP_PATH}/dist or /app/${APP_PATH}/out"; \
|
||||
echo "Contents of /app/${APP_PATH}:"; \
|
||||
ls -la /app/${APP_PATH}/ 2>/dev/null || echo "Directory does not exist"; \
|
||||
exit 1; \
|
||||
|
||||
Reference in New Issue
Block a user