Open ikuwow opened 1 year ago
When I run yarn run build
, I get the following error.
node v18.7.0
yarn run build
ncc: Version 0.20.5
ncc: Compiling file index.js
Error: error:0308010C:digital envelope routines::unsupported
at new Hash (node:internal/crypto/hash:71:19)
at Object.createHash (node:crypto:133:10)
at hashOf (evalmachine.<anonymous>:1:1478571)
at module.exports (evalmachine.<anonymous>:1:1480625)
at runCmd (evalmachine.<anonymous>:1:46940)
at 819 (evalmachine.<anonymous>:1:43967)
at __webpack_require__ (evalmachine.<anonymous>:1:216)
at startup (evalmachine.<anonymous>:1:353)
at module.exports.8 (evalmachine.<anonymous>:1:385)
at evalmachine.<anonymous>:1:395 {
opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
library: 'digital envelope routines',
reason: 'unsupported',
code: 'ERR_OSSL_EVP_UNSUPPORTED'
}
I was able to run build by setting the following NODE_OPTION.
export NODE_OPTIONS=--openssl-legacy-provider
yarn run build
ncc: Version 0.20.5
ncc: Compiling file index.js
ncc: Using typescript@4.9.4 (local user-provided)
1447kB dist/index.js
1447kB [1903ms] - ncc 0.20.5
Node.js 12 is EOL now https://github.com/nodejs/Release#release-schedule
https://github.com/yokawasa/gitrivy/blob/0ec2a8676dd30d85728945da8437bfd4d5f36644/.github/workflows/unittest.yml#L21