diff --git a/Dockerfile b/Dockerfile index 06f5835..c84a0b0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,11 +18,12 @@ ENV NEXT_TELEMETRY_DISABLED=1 ENV NODE_ENV=production \ PORT=3000 \ HOSTNAME="0.0.0.0" -RUN addgroup --system --gid 1001 nodejs && \ - adduser --system --uid 1001 nextjs +RUN groupadd --system --gid 1001 nodejs && \ + useradd --system --uid 1001 -g nodejs nextjs COPY --from=builder /app/public ./public COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./ COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static + USER nextjs EXPOSE 3000 CMD ["bun", "./server.js"]