npm v6.4.1 not running `prepare` inside docker npm v6.4.1 not running `prepare` inside docker docker docker

npm v6.4.1 not running `prepare` inside docker


That was an interesting rabbit hole. It is this bug: https://github.com/npm/npm/issues/17346. Prepare doesn't run as root. You could run the container as non-root, but I just used the fix in the issue.

I changed your last line to this

RUN source ~/.nvm/nvm.sh; npm config set unsafe-perm true; npm install jcollard/d3-ng2-service#jcollard/add-dist

Now it fails as expected.