opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ], library: 'digital envelope routines', reason: 'unsupported', code: 'ERR_OSSL_EVP_UNSUPPORTED' } Node.js v17.4.0
執(zhí)行npm run service時(shí),出現(xiàn)此錯(cuò)誤。目前node是v16.14.0版本,不斷重裝還是重複同樣的錯(cuò)誤,因?yàn)檫@些錯(cuò)誤在node v17中頻繁出現(xiàn)。
"scripts": { "serve": "export NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve", "build": "export NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service build", "lint": "export NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service lint" },
如果使用上面的程式碼,是可以執(zhí)行的,但是用docker建構(gòu)映像的時(shí)候又出現(xiàn)問題了。有解決辦法嗎?
在 Windows 中,我能夠使用以下方法解決此錯(cuò)誤:
"scripts": { "serve": "set NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve", ... }