mirror of
https://github.com/9technologygroup/patchmon.net.git
synced 2026-05-12 17:28:57 -05:00
fix: Improve Docker build reliability by cleaning npm cache before npm ci
- Move npm cache clean before npm ci to prevent corrupted package issues - This fixes the string_decoder error occurring during GitHub Actions builds
This commit is contained in:
@@ -46,10 +46,10 @@ COPY --chown=node:node backend/ ./backend/
|
||||
|
||||
WORKDIR /app/backend
|
||||
|
||||
RUN npm ci --ignore-scripts &&\
|
||||
RUN npm cache clean --force &&\
|
||||
npm ci --ignore-scripts &&\
|
||||
npx prisma generate &&\
|
||||
npm prune --omit=dev &&\
|
||||
npm cache clean --force
|
||||
npm prune --omit=dev
|
||||
|
||||
# Production stage
|
||||
FROM node:lts-alpine
|
||||
|
||||
Reference in New Issue
Block a user