Fix build by removing DB_URI build argument and using dummy connection
This commit is contained in:
parent
40ed4d773e
commit
750ef0398f
@ -25,8 +25,6 @@ services:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: webapp/Dockerfile
|
||||
args:
|
||||
- DB_URI=${DB_URI}
|
||||
container_name: infinity-webapp
|
||||
restart: always
|
||||
depends_on:
|
||||
|
||||
@ -11,10 +11,13 @@ RUN npm ci
|
||||
COPY webapp/ .
|
||||
|
||||
# Set environment variables for build
|
||||
ARG DB_URI
|
||||
ENV DB_URI=${DB_URI:-"mongodb://dummy:password@localhost:27017/dummy"}
|
||||
# Use a dummy DB_URI during build to prevent connection attempts
|
||||
ENV DB_URI="mongodb://dummy:password@localhost:27017/dummy"
|
||||
ENV NODE_ENV=production
|
||||
|
||||
# Disable Next.js telemetry during build
|
||||
ENV NEXT_TELEMETRY_DISABLED=1
|
||||
|
||||
# Build the application
|
||||
RUN npm run build
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user