Fix dev Dockerfile
This commit is contained in:
@ -18,6 +18,12 @@ RUN bunx prisma generate
|
|||||||
|
|
||||||
# Uncomment the following line in case you want to disable telemetry during the build.
|
# Uncomment the following line in case you want to disable telemetry during the build.
|
||||||
ENV NEXT_TELEMETRY_DISABLED=1
|
ENV NEXT_TELEMETRY_DISABLED=1
|
||||||
|
ARG GIT_SHA=unknown
|
||||||
|
ARG APP_VERSION=0.0.0
|
||||||
|
ARG DEPLOY_ENV=production
|
||||||
|
ENV NEXT_PUBLIC_GIT_SHA=$GIT_SHA \
|
||||||
|
NEXT_PUBLIC_APP_VERSION=$APP_VERSION \
|
||||||
|
NEXT_PUBLIC_DEPLOY_ENV=$DEPLOY_ENV
|
||||||
|
|
||||||
# Copy the rest of the code
|
# Copy the rest of the code
|
||||||
RUN bun run build -d
|
RUN bun run build -d
|
||||||
@ -31,7 +37,13 @@ ENV NEXT_TELEMETRY_DISABLED=1
|
|||||||
ENV NODE_ENV=production \
|
ENV NODE_ENV=production \
|
||||||
PORT=3000 \
|
PORT=3000 \
|
||||||
HOSTNAME="0.0.0.0"
|
HOSTNAME="0.0.0.0"
|
||||||
|
ARG GIT_SHA=unknown
|
||||||
|
ARG APP_VERSION=0.0.0
|
||||||
|
ARG DEPLOY_ENV=production
|
||||||
|
ENV NEXT_PUBLIC_GIT_SHA=$GIT_SHA \
|
||||||
|
NEXT_PUBLIC_APP_VERSION=$APP_VERSION \
|
||||||
|
NEXT_PUBLIC_DEPLOY_ENV=$DEPLOY_ENV
|
||||||
|
|
||||||
RUN groupadd --system --gid 1001 nodejs && \
|
RUN groupadd --system --gid 1001 nodejs && \
|
||||||
useradd --system --uid 1001 --no-log-init -g nodejs nextjs
|
useradd --system --uid 1001 --no-log-init -g nodejs nextjs
|
||||||
|
|
||||||
|
|||||||
@ -14,7 +14,6 @@ FROM base AS builder
|
|||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY --from=deps /app/node_modules ./node_modules
|
COPY --from=deps /app/node_modules ./node_modules
|
||||||
COPY . .
|
COPY . .
|
||||||
# RUN bunx prisma migrate deploy
|
|
||||||
RUN bunx prisma generate
|
RUN bunx prisma generate
|
||||||
|
|
||||||
# Uncomment the following line in case you want to disable telemetry during the build.
|
# Uncomment the following line in case you want to disable telemetry during the build.
|
||||||
|
|||||||
Reference in New Issue
Block a user