dockerfile:
FROM node:16.19.1 as builder
WORKDIR /build
COPY . .
RUN npm install
在linux主机上docker build 正常,但放到zadig上构建就报错:
#10 601.9 npm notice
#10 601.9 npm notice New major version of npm available! 8.19.3 → 9.8.0
#10 601.9 npm notice Changelog: https://github.com/npm/cli/releases/tag/v9.8.0
#10 601.9 npm notice Run npm install -g npm@9.8.0
to update!
#10 601.9 npm notice
#10 601.9 npm ERR! code ERR_SOCKET_TIMEOUT
#10 601.9 npm ERR! errno ERR_SOCKET_TIMEOUT
#10 601.9 npm ERR! network request to https://registry.npmmirror.com/yocto-queue/-/yocto-queue-0.1.0.tgz failed, reason: Socket timeout
#10 601.9 npm ERR! network This is a problem related to network connectivity.
#10 601.9 npm ERR! network In most cases you are behind a proxy or have bad network settings.
#10 601.9 npm ERR! network
#10 601.9 npm ERR! network If you are behind a proxy, please make sure that the
#10 601.9 npm ERR! network ‘proxy’ config is set properly. See: ‘npm help config’
#10 601.9
#10 601.9 npm ERR! A complete log of this run can be found in:
#10 601.9 npm ERR! /root/.npm/_logs/2023-07-17T10_20_10_965Z-debug-0.log
经过实际测试,上面报错的 yocto-queue-0.1.0.tgz 文件url,是能够正常下载的,包括进入zadig创建的构建job的容器上,也是能够正常下载。