mirror of
https://github.com/9technologygroup/patchmon.net.git
synced 2026-05-12 09:18:38 -05:00
fix: Use npm install to regenerate package-lock.json and bypass corruption
- Delete package-lock.json in Docker build to avoid corrupted string_decoder entry - Use npm install instead of npm ci to regenerate package-lock.json fresh - This avoids the 'string_decoder is a core module' error that package-lock.json had cached
This commit is contained in:
@@ -47,8 +47,8 @@ COPY --chown=node:node backend/ ./backend/
|
||||
WORKDIR /app/backend
|
||||
|
||||
RUN npm cache clean --force &&\
|
||||
rm -rf node_modules ~/.npm /root/.npm &&\
|
||||
npm ci --ignore-scripts --legacy-peer-deps --no-audit --prefer-online --fetch-retries=0 &&\
|
||||
rm -rf node_modules ~/.npm /root/.npm package-lock.json &&\
|
||||
npm install --omit=dev --ignore-scripts --legacy-peer-deps --no-audit --prefer-online --fetch-retries=0 &&\
|
||||
npm run db:generate &&\
|
||||
npm prune --omit=dev &&\
|
||||
npm cache clean --force
|
||||
|
||||
Reference in New Issue
Block a user