Update Docker Compose, Next.js config, and GitHub Actions for optimized CI/CD. Added local build notes, skipped ESLint during CI builds, and modified deployment to use prebuilt artifacts for faster image creation.

This commit is contained in:
smhk1376 committed 2026-09-24 15:25:08 +03:30
1 parent 648777c649
commit 19b75671a0
4 files changed
+84 -11

No files matched your search

+25
View File
@@ -0,0 +1,25 @@
# Packs a pre-built Next.js standalone output — no npm / next build on the server.
# Expects build context:
# prebuilt/standalone/ ← contents of .next/standalone
# prebuilt/static/ ← contents of .next/static
# prebuilt/public/ ← public/
FROM node:22-alpine AS runner
WORKDIR /app
ENV NODE_ENV=production
ENV NEXT_TELEMETRY_DISABLED=1
ENV PORT=3000
ENV HOSTNAME=0.0.0.0
RUN addgroup --system --gid 1001 nodejs \
&& adduser --system --uid 1001 nextjs
COPY --chown=nextjs:nodejs prebuilt/standalone/ ./
COPY --chown=nextjs:nodejs prebuilt/public ./public
COPY --chown=nextjs:nodejs prebuilt/static ./.next/static
USER nextjs
EXPOSE 3000
CMD ["node", "server.js"]