【问题标题】:node js npm install of github packages failinggithub包的node js npm安装失败
【发布时间】:2014-09-16 22:01:44
【问题描述】:

目前正在尝试安装 node js 模块,其中一些安装得很好,但那些需要 gihub 的说 npm ERR! fetch 失败,比如 npm install socket.io 给出了

npm 错误!获取失败https://github.com/LearnBoost/node-XMLHttpRequest/archive/0f36d0b5ebc03d85f860d42a64ae9791e1daa433.tar.gz

ws@0.4.31 安装 /home/robert/node_modules/socket.io/node_modules/engine.io/node_modules/ws (node-gyp 重建 2> builderror.log) || (0号出口)

make: 进入目录/home/robert/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build' CXX(target) Release/obj.target/bufferutil/src/bufferutil.o SOLINK_MODULE(target) Release/obj.target/bufferutil.node SOLINK_MODULE(target) Release/obj.target/bufferutil.node: Finished COPY Release/bufferutil.node CXX(target) Release/obj.target/validation/src/validation.o SOLINK_MODULE(target) Release/obj.target/validation.node SOLINK_MODULE(target) Release/obj.target/validation.node: Finished COPY Release/validation.node make: Leaving directory/home/robert/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build'

我已经运行 npm config set registry "http://registry.npmjs.org/" 和 npm config set strict-ssl false

是否可以从 zip 文件安装 npm 更新?因为我可以通过 firefox 访问失败的 github url,这样就可以下载它们。

我在代理后面运行,但已将其添加到 npm 配置文件和 apt.conf 文件中,因此我可以正确 apt-get 或 git clone 正常,有什么想法吗? 我正在运行 ubuntu 服务器,14.04 已完全更新

【问题讨论】:

标签: node.js git ubuntu github npm


【解决方案1】:

这个问题看起来像是你的代理的问题,以及他如何处理 github 访问。 请使用本站的搜索功能和google,你会发现很多相关的问题。

我认为这个问题可能会对您有所帮助: git is blocked, how to install npm modules

附: https://www.google.com/search?btnG=1&pws=0&q=npm+github+proxy&gws_rd=ssl

【讨论】:

    猜你喜欢
    • 2020-02-25
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2022-01-26
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多