fix(build): use Debian Node image
Build Push and Deploy / docker-image (push) Failing after 31s
Build Push and Deploy / deploy-fallback-log (push) Successful in 1s

This commit is contained in:
2026-07-08 19:20:29 +08:00
parent 76e62a2d3d
commit 67c1a88afe
+8 -8
View File
@@ -1,14 +1,14 @@
FROM refinedev/node:22 AS base FROM node:22-bookworm-slim AS base
WORKDIR /app/refine
FROM base AS deps FROM base AS deps
RUN apk add --no-cache libc6-compat
COPY package.json yarn.lock* package-lock.json* pnpm-lock.yaml* .npmrc* ./ COPY package.json yarn.lock* package-lock.json* pnpm-lock.yaml* .npmrc* ./
RUN \ RUN \
if [ -f yarn.lock ]; then yarn --frozen-lockfile; \ if [ -f yarn.lock ]; then yarn --frozen-lockfile; \
elif [ -f package-lock.json ]; then npm ci --no-audit --no-fund; \ elif [ -f package-lock.json ]; then npm ci; \
elif [ -f pnpm-lock.yaml ]; then yarn global add pnpm && pnpm i --frozen-lockfile; \ elif [ -f pnpm-lock.yaml ]; then yarn global add pnpm && pnpm i --frozen-lockfile; \
else echo "Lockfile not found." && exit 1; \ else echo "Lockfile not found." && exit 1; \
fi fi
@@ -40,12 +40,12 @@ ENV NODE_ENV=production
COPY --from=builder /app/refine/public ./public COPY --from=builder /app/refine/public ./public
RUN mkdir .next RUN mkdir .next
RUN chown refine:nodejs .next RUN chown node:node .next
COPY --from=builder --chown=refine:nodejs /app/refine/.next/standalone ./ COPY --from=builder --chown=node:node /app/refine/.next/standalone ./
COPY --from=builder --chown=refine:nodejs /app/refine/.next/static ./.next/static COPY --from=builder --chown=node:node /app/refine/.next/static ./.next/static
USER refine USER node
EXPOSE 3000 EXPOSE 3000