While running FlowJS check
node_modules/.bin/flow check inside docker image based on node:latest (currently 6.5)
You see error
$ npm i
...
npm info lifecycle [email protected]~postinstall: [email protected]
> [email protected] postinstall .../node_modules/flow-bin
> node lib/install.js
✖ The `.../node_modules/flow-bin/vendor/flow` binary doesn't seem to work correctly
✖ flow binary test failed
...
$ node_modules/.bin/flow check
.../node_modules/flow-bin/vendor/flow: error while loading shared libraries: libelf.so.1: cannot open shared object file: No such file or directory
ERROR: Build failed: exit code 1
E.g. flow cannot be run under vanilla node:latest docker image
Related issue https://github.com/facebook/flow/issues/210
In case your image is from node:latest (which is debian:jessie under the hood)
you need to add a little bit update to apt:
$ apt-get update -qq
$ apt-get install -qy libelf1
before any runs (e.g. in Dockerfile or corresponding section of .gitlab-ci.yml)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With