首页 > 编程语言 >NodeJs——error:03000086:digital envelope routines::initialization error

NodeJs——error:03000086:digital envelope routines::initialization error

时间:2024-01-17 13:13:50浏览次数:46  
标签:node www ad NodeJs initialization modules wwwroot client error

前言

vue2前端项目在服务器上打包报错,发现是高版本的node使用的是OpenSSL 3.0,导致的不兼容,所以先临时抛出下环境变量,继续使用老板本的OpenSSL的实现;

步骤

解决方法

export NODE_OPTIONS=--openssl-legacy-provider

具体报错信息

root@iZuf6f5trc95ufa25hqb6eZ:/www/wwwroot/ad-client# pnpm run build

> [email protected] build /www/wwwroot/ad-client
> vue-cli-service build


⠹  Building for production...Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:71:19)
    at Object.createHash (node:crypto:133:10)
    at module.exports (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/util/createHash.js:135:53)
    at NormalModule._initBuildHash (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:417:16)
    at handleParseError (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:471:10)
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:503:5
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:358:12
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:373:3
    at iterateNormalLoaders (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:214:10)
    at iterateNormalLoaders (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:221:10)
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:236:3
    at runSyncOrAsync (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:130:11)
    at iterateNormalLoaders (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:232:2)
    at Array.<anonymous> (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:205:4)
    at Storage.finished (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:55:16)
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:91:9
⠋  Building for production.../www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:114
			throw e;
			^

Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:71:19)
    at Object.createHash (node:crypto:133:10)
    at module.exports (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/util/createHash.js:135:53)
    at NormalModule._initBuildHash (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:417:16)
    at handleParseError (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:471:10)
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:503:5
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/webpack/lib/NormalModule.js:358:12
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:373:3
    at iterateNormalLoaders (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:214:10)
    at iterateNormalLoaders (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:221:10)
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:236:3
    at context.callback (/www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/loader-runner/lib/LoaderRunner.js:111:13)
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected][email protected]/node_modules/cache-loader/dist/index.js:147:7
    at /www/wwwroot/ad-client/node_modules/.pnpm/[email protected]/node_modules/graceful-fs/graceful-fs.js:61:14
    at FSReqCallback.oncomplete (node:fs:198:23) {
  opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
  library: 'digital envelope routines',
  reason: 'unsupported',
  code: 'ERR_OSSL_EVP_UNSUPPORTED'
}

Node.js v18.16.0

标签:node,www,ad,NodeJs,initialization,modules,wwwroot,client,error
From: https://www.cnblogs.com/wangyang0210/p/17969789

相关文章

  • 使用zipFile读取文件时遇到的问题及解决(KeyError: "There is no item named 'xxx' in
    问题描述在Windows上跑一段代码时,遇到如下问题:KeyError:"Thereisnoitemnamed'CDR_Data\\\\CDR.Corpus.v010516\\\\CDR_DevelopmentSet.PubTator.txt'inthearchive"原因分析这是一段Python代码,代码中使用到了zipfile库,它首先创建了一个ZipFile对象,然后在调用read()......
  • CommandNotFoundError: Your shell has not been properly configured to use ‘conda
    问题描述使用condaactivate激活虚拟环境时报错:condaactivatevirtual_env提示内容CommandNotFoundError:Yourshellhasnotbeenproperlyconfiguredtouse'condaactivate'.Toinitializeyourshell,run$condainit<SHELL_NAME>Currentlysupp......
  • Linux7安装 Oracle 11g Error in invoking target 'agent nmhs' of makefile
    目录1现象2解决3附录1现象%86时出现报错Errorininvokingtarget'agentnmhs'ofmakefile2解决在makefile中添加链接libnnz11库的参数修改$ORACLE_HOME/sysman/lib/ins_emagent.mk,将$(MK_EMAGENT_NMECTL)修改为:$(MK_EMAGENT_NMECTL)-lnnz11建议修改前备份原始......
  • Import yaml ModuleNotFoundError No module named 'yaml
    ImportyamlModuleNotFoundError:Nomodulenamed'yaml'Python错误信息:ModuleNotFoundError异常,具体错误是找不到名为yaml的模块。这意味着在执行导入语句importyaml时,Python解释器没有在你的环境里找到这个模块。yaml是一个用于处理YAML数据格式的库,如果你在代码中需要解......
  • 安装torch2trt中遇到的报错:ModuleNotFoundError: No module named 'torch2trt.flatten
    这一个报错折腾了一整天,在这里记录一下方便他人可以快速解决问题:首先说明一下本人的版本情况:Linux系统CUDA:11.8Python:3.8torch:2.0.0torchvision:0.15.0代码中报错的位置是:fromtorch2trtimporttorch2trt报错的原因是:ModuleNotFoundError:Nomodulenamed'torch2trt......
  • 《nodejs安装篇》nodejs卸载及重装
    参考链接:https://blog.csdn.net/strawberry_x/article/details/113648770?spm=1001.2014.3001.5501卸载首先在控制面板的程序中卸载nodejs然后删除这两个文件夹然后检查是否有一下文件夹,若有,就删除c://user/xxx/node_modelsc://ProgramFiels/nodejsc://user/xxx/AppData/......
  • 《nodejs安装篇》nodejs安装windows详细版
    参考链接:https://www.cnblogs.com/feiye512/p/12539306.html安装1、下载安装包下载地址:https://nodejs.org/zh-cn/download/根据自己电脑系统及位数选择,我这里选择windows64位.msi格式安装包.msi和.zip格式区别:1、.msi是Windowsinstaller开发出来的程序安装文件,它可以让你......
  • 《nodejs新建篇》nvm安装
    参考链接:https://www.cnblogs.com/jing-tian/p/11225123.html介绍nvm是node.js的版本管理工具,可以运行在多种操作系统上。nvmforwindows是使用go语言编写的软件。我电脑使用的是Windows操作系统,所以我要记录下在此操作系统上nvm的安装和使用。下载nvm-windows最新下载......
  • 《nodejs安装篇》nodejs安装
    安装参考链接:https://www.runoob.com/nodejs/nodejs-install-setup.html本安装教程以Node.jsv4.4.3LTS(长期支持版本)版本为例。Node.js安装包及源码下载地址为:https://nodejs.org/zh-cn/download/。你可以根据不同平台系统选择你需要的Node.js安装包。Node.js历史版......
  • 《nodejs概念篇》ES6
    ES6简介参考链接:https://www.cnblogs.com/itzlg/p/11854386.htmlECMAScript6.0(简称ES6),是JavaScript语言的下一代标准。它的目标是使得JavaScript语言可以用来编写复杂的大型应用程序,成为企业级开发语言。es6入门文档:http://caibaojian.com/es6/ES6的新特性参考链接:https://w......