From a673675044d200f7c8c8d00a4a7c87b439f8b95a Mon Sep 17 00:00:00 2001 From: mukesh13 Date: Mon, 16 Jun 2025 20:21:39 +0530 Subject: [PATCH] Docker config --- Dockerfile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 95b7b3e..2878647 100644 --- a/Dockerfile +++ b/Dockerfile @@ -42,14 +42,14 @@ ENV NODE_ENV production # Uncomment the following line in case you want to disable telemetry during runtime. # ENV NEXT_TELEMETRY_DISABLED 1 -RUN addgroup --system --gid 1001 nodejs -RUN adduser --system --uid 1001 nextjs +# Create user and group in one step for faster builds +RUN addgroup --system --gid 1001 nodejs && \ + adduser --system --uid 1001 nextjs COPY --from=builder /app/public ./public # Set the correct permission for prerender cache -RUN mkdir .next -RUN chown nextjs:nodejs .next +RUN mkdir .next && chown nextjs:nodejs .next # Automatically leverage output traces to reduce image size # https://nextjs.org/docs/advanced-features/output-file-tracing