参考:https://askubuntu.com/questions/1088662/npm-depends-node-gyp-0-10-9-but-it-is-not-going-to-be-installed sudo apt-get install nodejs-dev node-gyp libssl1.0-dev sudo apt-get install npm 即可。亲测有效。