diff --git a/Dockerfile.web b/Dockerfile.web index 28efaf4a7..dcad66206 100644 --- a/Dockerfile.web +++ b/Dockerfile.web @@ -54,11 +54,11 @@ RUN addgroup --system --gid 1001 nodejs && \ adduser --system --uid 1001 nextjs # Copy standalone output (includes traced node_modules) -COPY --from=builder /app/apps/web/.next/standalone ./ +COPY --from=builder --chown=nextjs:nodejs /app/apps/web/.next/standalone ./ # Copy static files (not included in standalone) -COPY --from=builder /app/apps/web/.next/static ./apps/web/.next/static +COPY --from=builder --chown=nextjs:nodejs /app/apps/web/.next/static ./apps/web/.next/static # Copy public assets -COPY --from=builder /app/apps/web/public ./apps/web/public +COPY --from=builder --chown=nextjs:nodejs /app/apps/web/public ./apps/web/public USER nextjs