node切换淘宝源报错

报的错误:

[root@localhost ~]# npm install -g cnpm --registry=https://registry.npm.taobao.org
npm ERR! code CERT_NOT_YET_VALID
npm ERR! errno CERT_NOT_YET_VALID
npm ERR! request to https://registry.npm.taobao.org/cnpm failed, reason: certificate is not yet valid

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2006-01-23T01_49_05_762Z-debug.log

解决:

同步ntp:

ntpdate 172.16.2.26

_Kc
发布了69 篇原创文章 · 获赞 9 · 访问量 7万+

猜你喜欢

转载自blog.csdn.net/qq_26775359/article/details/85089177