nodejs 出错:npm ERR! code ERR_TLS_CERT_ALTNAME_INVALID ?
原创 sorryboy 发表于:2020-06-08 17:40:57
  阅读 :740   收藏   编辑

console:

npm ERR! code ERR_TLS_CERT_ALTNAME_INVALID
npm ERR! errno ERR_TLS_CERT_ALTNAME_INVALID
npm ERR! request to https://registry.cnpmjs.org/@tarojs%2fcli 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

解决:
关闭ssl

npm config set strict-ssl false