Cannot install on debian9
See original GitHub issueSystem information
- node version: v10.14.0
- npm or yarn version: 6.4.1
- OS/version/architecture: linux - debian9 / 4.15.0-39-generic / x64
- Applicable nodegit version: 0.23.0
When installing on debian9 after installing the required deps you get this error:
[nodegit] WARN - Could not finish postinstall { Error: Command failed: node “/node_modules/nodegit/dist/nodegit.js” /node_modules/nodegit/dist/nodegit.js:16 throw ex; ^ Error: libcrypto.so.1.0.0: cannot open shared object file: No such file or directory at Object.Module._extensions…node (internal/modules/cjs/loader.js:717:18) at Module.load (internal/modules/cjs/loader.js:598:32) at tryModuleLoad (internal/modules/cjs/loader.js:537:12) at Function.Module._load (internal/modules/cjs/loader.js:529:3) at Module.require (internal/modules/cjs/loader.js:636:17) at require (internal/modules/cjs/helpers.js:20:18) at Object.<anonymous> (/node_modules/nodegit/dist/nodegit.js:12:12) at Module._compile (internal/modules/cjs/loader.js:688:30) at Object.Module._extensions…js (internal/modules/cjs/loader.js:699:10) at Module.load (internal/modules/cjs/loader.js:598:32) at ChildProcess.exithandler (child_process.js:289:12) at ChildProcess.emit (events.js:182:13) at maybeClose (internal/child_process.js:962:16) at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5) killed: false, code: 1, signal: null, cmd: ‘node “/node_modules/nodegit/dist/nodegit.js”’ }
Here’s the script required to reproduce this in a docker container.
docker run --rm -it gcr.io/google-appengine/debian9 bash
apt update && apt install -y curl gnupg
curl -sL https://deb.nodesource.com/setup_10.x | bash -
apt install -y nodejs
apt install -y libcurl4-gnutls-dev
npm install nodegit
or as a single command
docker run --rm gcr.io/google-appengine/debian9 bash -c "apt update && apt install -y curl gnupg && curl -sL https://deb.nodesource.com/setup_10.x | bash - && apt install -y nodejs libcurl4-gnutls-dev && npm install nodegit"
It may be a little naive but ideally the dependencies on system libs should be removed. This makes it very difficult for us to use since our applications are used in a variety of OS’s and distributions.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:6
- Comments:15 (5 by maintainers)
Top GitHub Comments
That doesn’t solve this issue, it’s simply a workaround. Also it requires even more system dependencies to be able to build it in the first place which is just as bad requiring our targets to install those.
It’s fine to have a prebuild that only works for some people. What’s bad is that the installer code is unable to notice that fact.
I realize that is mostly node-pre-gyp’s fault for having an incomplete model of what it means to locate a compatible build. But the knowledge of which libraries are needed belongs inside nodegit regardless, and before spawning node-pre-gyp it could verify known preconditions that should cause it to force a local build.