SSL错误:dotCloud上的CERT_UNTRUSTED

 孙誉嘉两_365 发布于 2023-02-06 20:24

在dotCloud上部署Node.js服务时,我看到以下错误:

23:03:59.958870: [www] npm ERR! Error: SSL Error: CERT_UNTRUSTED
23:03:59.959405: [www] npm ERR!     at ClientRequest. (/opt/node/v0.8.3/lib/node_modules/npm/node_modules/request/main.js:440:26)
23:03:59.959736: [www] npm ERR!     at ClientRequest.g (events.js:185:14)
23:03:59.960068: [www] npm ERR!     at ClientRequest.EventEmitter.emit (events.js:88:17)
23:03:59.960399: [www] npm ERR!     at HTTPParser.parserOnIncomingClient [as onIncoming] (http.js:1445:7)
23:03:59.968852: [www] npm ERR!     at HTTPParser.parserOnHeadersComplete [as onHeadersComplete] (http.js:111:23)
23:03:59.969361: [www] npm ERR!     at CleartextStream.socketOnData [as ondata] (http.js:1356:20)
23:03:59.969696: [www] npm ERR!     at CleartextStream.CryptoStream._push (tls.js:396:27)
23:03:59.970028: [www] npm ERR!     at SecurePair.cycle (tls.js:750:20)
23:03:59.970359: [www] npm ERR!     at EncryptedStream.CryptoStream.write (tls.js:131:13)
23:03:59.970694: [www] npm ERR!     at Socket.ondata (stream.js:38:26)
23:03:59.971012: [www] npm ERR! If you need help, you may report this log at:
23:03:59.971299: [www] npm ERR!     
23:03:59.971587: [www] npm ERR! or email it to:
23:03:59.971876: [www] npm ERR!     
23:03:59.972208: [www]
23:03:59.972543: [www] npm ERR! System Linux 2.6.38.2-grsec-dotcloud-ec2
23:03:59.972852: [www] npm ERR! command "node" "/opt/node/default/bin/npm" "install"
23:03:59.973251: [www] npm ERR! cwd /home/dotcloud/rsync-1388703750593/app
23:03:59.973584: [www] npm ERR! node -v v0.8.3
23:03:59.973914: [www] npm ERR! npm -v 1.1.44
23:04:00.331100: [www] npm ERR!
23:04:00.331630: [www] npm ERR! Additional logging details can be found in:
23:04:00.331955: [www] npm ERR!     /home/dotcloud/rsync-1388703750593/app/npm-debug.log
23:04:00.332280: [www] npm ERR! not ok code 0
23:04:01.058860: [www] -- Build failed: "npm install" failed with return code 1

alex.. 10

更新您的节点/ npm(首选),或运行npm config set ca null.

他们最近在npmjs.org更改了证书,因为旧版本已过期,但你的npm已将旧版本硬编码到其中.

PS:将strict-ssl设置为false是一个非常糟糕的主意,除非你知道你在做什么.

1 个回答
  • 更新您的节点/ npm(首选),或运行npm config set ca null.

    他们最近在npmjs.org更改了证书,因为旧版本已过期,但你的npm已将旧版本硬编码到其中.

    PS:将strict-ssl设置为false是一个非常糟糕的主意,除非你知道你在做什么.

    2023-02-06 20:27 回答
撰写答案
今天,你开发时遇到什么问题呢?
立即提问
热门标签
PHP1.CN | 中国最专业的PHP中文社区 | PNG素材下载 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有