Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error during docker build #1825

Open
Nexyll opened this issue Oct 9, 2023 · 1 comment
Open

Error during docker build #1825

Nexyll opened this issue Oct 9, 2023 · 1 comment

Comments

@Nexyll
Copy link

Nexyll commented Oct 9, 2023

I use the script available in deployments/build.sh to build a docker image with the current version of the develop branch and I get the following error:

Error message
+ npm run build
138.7
138.7 > codimd@2.4.2 build
138.7 > webpack --config webpack.prod.js --display errors-only -p
138.7
139.7 node:internal/crypto/hash:71
139.7   this[kHandle] = new _Hash(algorithm, xofLen);
139.7                   ^
139.7
139.7 Error: error:0308010C:digital envelope routines::unsupported
139.7     at new Hash (node:internal/crypto/hash:71:19)
139.7     at Object.createHash (node:crypto:133:10)
139.7     at module.exports (/home/hackmd/app/node_modules/webpack/lib/util/createHash.js:135:53)
139.7     at NormalModule._initBuildHash (/home/hackmd/app/node_modules/webpack/lib/NormalModule.js:412:16)
139.7     at handleParseError (/home/hackmd/app/node_modules/webpack/lib/NormalModule.js:463:10)
139.7     at /home/hackmd/app/node_modules/webpack/lib/NormalModule.js:495:5
139.7     at /home/hackmd/app/node_modules/webpack/lib/NormalModule.js:354:12
139.7     at /home/hackmd/app/node_modules/loader-runner/lib/LoaderRunner.js:373:3
139.7     at iterateNormalLoaders (/home/hackmd/app/node_modules/loader-runner/lib/LoaderRunner.js:214:10)
139.7     at Array.<anonymous> (/home/hackmd/app/node_modules/loader-runner/lib/LoaderRunner.js:205:4)
139.7     at Storage.finished (/home/hackmd/app/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:55:16)
139.7     at /home/hackmd/app/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:91:9
139.7     at /home/hackmd/app/node_modules/graceful-fs/graceful-fs.js:90:16
139.7     at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3) {
139.7   opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
139.7   library: 'digital envelope routines',
139.7   reason: 'unsupported',
139.7   code: 'ERR_OSSL_EVP_UNSUPPORTED'
139.7 }
139.7
139.7 Node.js v18.16.0

I used the following command to launch the build: ./build.sh hackmdio/runtime:18.16.0-f5fd28b4 hackmdio/buildpack:18.16.0-f5fd28b4
using buildpack for node 18

I also get the same error when I run the npm run build command locally with Node 18.

@Tweniee
Copy link

Tweniee commented Nov 10, 2023

try downgrading the node v18 to v16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants