Fix user group
Build and push Docker image / build-and-push (push) Successful in 3m43s

This commit is contained in:
2026-08-31 04:52:16 +02:00
parent 3defe60bb9
commit b11366fb4e
+4 -5
View File
@@ -30,16 +30,15 @@ WORKDIR /app
ENV NODE_ENV=production
RUN addgroup --system --gid 1001 nodejs
RUN adduser --system --uid 1001 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
RUN mkdir -p data && chown nextjs:nodejs data
RUN mkdir -p data/images && chown nextjs:nodejs data/images
RUN addgroup --system --gid 1001 nodejs \
&& adduser --system --uid 1001 --ingroup nodejs nextjs \
&& mkdir -p /app/data/images \
&& chown -R nextjs:nodejs /app/data
USER nextjs