From 5e971e96db366437dac827069b2a7e8698cb77fc Mon Sep 17 00:00:00 2001 From: bagas Date: Sat, 3 Jan 2026 20:54:55 +0700 Subject: [PATCH] update build --- Dockerfile | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index df1f03c..b316521 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,22 +13,17 @@ COPY --from=deps /app/node_modules ./node_modules COPY . . RUN npm run build -FROM node:22-alpine AS runner +FROM gcr.io/distroless/nodejs22-debian12 AS runner WORKDIR /app ENV NODE_ENV=production ENV NEXT_TELEMETRY_DISABLED=1 ENV PORT=3000 ENV HOSTNAME=0.0.0.0 -RUN addgroup -g 1001 -S nodejs \ - && adduser -S nextjs -u 1001 -G nodejs - -# COPY --from=builder /app/public ./public COPY --from=builder /app/.next/standalone ./ COPY --from=builder /app/.next/static ./.next/static - -USER nextjs +# COPY --from=builder /app/public ./public EXPOSE 3000 -CMD ["node", "server.js"] +CMD ["server.js"]