首页 > 其他分享 >npm ERR! request to https://registry.npm.taobao.org/axios failed, reason: certificate has expired

npm ERR! request to https://registry.npm.taobao.org/axios failed, reason: certificate has expired

时间:2024-01-22 22:23:22浏览次数:26  
标签:npm axios certificate ERR https expired

前言

一直使用 npm build没问题的,突然出现报错:

npm WARN install Usage of the `--dev` option is deprecated. Use `--only=dev` instead.
npm ERR! code CERT_HAS_EXPIRED
npm ERR! errno CERT_HAS_EXPIRED
npm ERR! request to https://registry.npm.taobao.org/axios failed, reason: certificate has expired

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2024-01-22T06_15_36_690Z-debug.log

解决方案

npm config set strict-ssl false

This is a alternative shared in this url https://github.com/nodejs/node/issues/3742

标签:npm,axios,certificate,ERR,https,expired
From: https://www.cnblogs.com/niuben/p/17979985

相关文章

  • request to https://registry.npm.taobao.org/vue-loader failed!
    npminstall报错:requestto https://registry.npm.taobao.org/vue-loader failed,reason:getaddrinfoENOTFOUNDregistry.npm.taobao.org解决:https://jingyan.baidu.com/article/acf728fd99b16ff8e510a301.html查看镜像源:npmgetregistryhttps://registry.npmjs.org/国......
  • nvm 报错 Could not retrieve https://npm.taobao.org/mirrors/node/*************
    nvminstall(listavailable)报错Couldnotretrievehttps://npm.taobao.org/mirrors/node/*************出现这个错误的原因是淘宝不知道啥时候换镜像源地址了 打开nvm安装目录找到 settings.txt文件 地址更换为node_mirror:https://cdn.npmmirror.com/binari......
  • npm ERR! code 1 npm ERR! path E:\20231213\vue-element-admin\node_modules\nod
    执行npminstall报错,根据下面报错信息可知,是由于nodejs和node-sass版本不一致造成的,也就是当前项目比较旧,而我安装的nodejs比较新。PSE:\20231213\vue-element-admin>PSE:\20231213\vue-element-admin>PSE:\20231213\vue-element-admin>PSE:\20231213\vue-element-adm......
  • [安全警报] Npm木马利用“Oscompatible“包悄然安装AnyDesk
    最近,一个名为OsCompatible的恶意包被上传到npm。该包被发现包含一个针对Windows的远程访问木马。这个名为OsCompatible的软件包于2024年1月9日发布,在被撤下之前共吸引了380次下载。据了解,OsCompatible包含“几个奇怪的二进制文件”,包括一个可执行文件、一个动态链接库(DLL)和一......
  • npm常用命令
    1、设置安装源npmconfigsetregistryhttps://registry.npm.taobao.org2、验证安装源npmconfiggetregistry3、cnpm安装npminstall-gcnpm--registry=https://registry.npm.taobao.org4、使用cnpmcnpminstallxxx5、yarn安装npminstall-gyarn6、yarn版本查......
  • npm的使用
    01.首先在项目中在文件资源管理器中打开 02.然后选择在终端打开 03.初始化命令npminit,以及一些包命名 04.一些常用的npm命令 ......
  • npm 换源
    npmconfigsetregistryhttps://registry.npmmirror.com/原淘宝镜像源https://registry.npm.taobao.org,现已更换为https://registry.npmmirror.com。相关链接:淘宝NPM镜像站切换新域名啦npm配置文件位于~/.npmrc:registry=https://registry.npmmirror.com/你也可以......
  • 使用pnpm来管理vue项目的node_modules
    要使用pnpm,先确保nodejs版本在16以上(目前用的18.16.1)(确保本地已经全局安装了pnpm如果没有安装就使用npmi-gpnpm来全局安装)一.老项目从npm迁移到pnpm  先删掉项目中的node_modules文件夹和package-lock.json文件   在终端运行pnpmi 安装成功后根目录下会多一......
  • npm 的使用总结
    一、新域名官方地址:https://npmmirror.com镜像地址:https://registry.npmmirror.com老域名:http://npm.taobao.org和http://registry.npm.taobao.org将在2022.06.30号正式下线和停止DNS解析原来的 registry.npm.taobao.org 已替换为 registry.npmmirror.c......
  • 解决npm run start 和 node.js src/main.js 引用资源文件路径不一致问题
    解决npmrunstart和node.jssrc/main.js引用资源文件路径不一致问题问题描述写了一个node.js连接sqlite3数据库的项目,因为数据库sqlite3.db文件相对于根目录和src/main.js路径不一致,打包时总有一种方法失败分析原因数据库sqlite3.db文件是相对控制台运行命令的相对路径npmrun......