mirror of
https://github.com/9technologygroup/patchmon.net.git
synced 2026-05-22 07:49:46 -05:00
fix: Add npm fetch retries to handle transient network errors
ARM64 builds under QEMU are slower and more prone to network timeouts. Changed from --fetch-retries=0 to --fetch-retries=3 with exponential backoff: - Min timeout: 20 seconds - Max timeout: 120 seconds This should handle transient ECONNRESET errors from npm registry.
This commit is contained in:
@@ -48,7 +48,7 @@ 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 &&\
|
||||
npm ci --ignore-scripts --legacy-peer-deps --no-audit --prefer-online --fetch-retries=3 --fetch-retry-mintimeout=20000 --fetch-retry-maxtimeout=120000 &&\
|
||||
PRISMA_CLI_BINARY_TYPE=binary npm run db:generate &&\
|
||||
npm prune --omit=dev &&\
|
||||
npm cache clean --force
|
||||
|
||||
@@ -23,7 +23,7 @@ COPY frontend/package*.json ./
|
||||
|
||||
RUN npm cache clean --force &&\
|
||||
rm -rf node_modules ~/.npm /root/.npm &&\
|
||||
npm install --ignore-scripts --legacy-peer-deps --no-audit --prefer-online --fetch-retries=0
|
||||
npm install --ignore-scripts --legacy-peer-deps --no-audit --prefer-online --fetch-retries=3 --fetch-retry-mintimeout=20000 --fetch-retry-maxtimeout=120000
|
||||
|
||||
COPY frontend/ ./
|
||||
|
||||
|
||||
Reference in New Issue
Block a user