npm install certificate has expired 证书过期的解决办法
npm install 时 certificate has expired 错误的解决办法
报错:npm ERR! request to https://registry.npm.taobao.org/events failed, reason: certificate has expired
shell
复制代码
npm install
npm ERR! code CERT_HAS_EXPIRED
npm ERR! errno CERT_HAS_EXPIRED
npm ERR! request to https://registry.npm.taobao.org/events failed, reason: certificate has expired
npm ERR! A complete log of this run can be found in:
npm ERR! /.npm/_logs/2024-01-24T08_52_27_547Z-debug.log
ERROR: Job failed: exit status 1
原因:证书过期
简单粗暴的解决办法:
关闭 npm ssl 严格证书检查
shell
复制代码
npm set strict-ssl false
或切换到官方源:
npm config set registry https://registry.npmjs.org/
淘宝镜像源
npm config set registry https://registry.npmmirror.com
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】凌霞软件回馈社区,博客园 & 1Panel & Halo 联合会员上线
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】博客园社区专享云产品让利特惠,阿里云新客6.5折上折
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· DeepSeek “源神”启动!「GitHub 热点速览」
· 微软正式发布.NET 10 Preview 1:开启下一代开发框架新篇章
· C# 集成 DeepSeek 模型实现 AI 私有化(本地部署与 API 调用教程)
· DeepSeek R1 简明指南:架构、训练、本地部署及硬件要求
· 2 本地部署DeepSeek模型构建本地知识库+联网搜索详细步骤
2021-02-04 基于 GlusterFS 实现 Docker 集群的分布式存储
2021-02-04 Keepalive+Haproxy+Mycat高可用环境搭建