您的位置:首页 > Web前端 > Node.js

node报错npm ERR! code ERR_TLS_CERT_ALTNAME_INVALID npm ERR! npm ERR! request to https://registry.cnpmj

2020-06-25 04:55 1236 查看

npm ERR! code ERR_TLS_CERT_ALTNAME_INVALID
npm ERR! errno ERR_TLS_CERT_ALTNAME_INVALID
npm ERR! request to https://registry.cnpmjs.org/vue-cli failed, reason: Hostname/IP does not match certificate's altnames: Host: registry.cnpmjs.org. is not in the cert's altnames: DNS:r.cnpmjs.org

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\yy\AppData\Roaming\npm-cache\_logs\2020-06-12T05_41_01_727Z-debug.log

 

在使用npm install -g npm 时报的错!

解决办法:

输入:

  1. npm config set strict-ssl false
  2. npm install -g supervisor

之后再输入npm install -g npm即可

 

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐