Jenkin's build failing on npm install
There are several problems here.
It looks like you are using node
0.11. Why? Do you need a feature from that unstable branch?
If not, I would recommend using the nodesource packaged node
modules, as described here: https://github.com/nodesource/distributions#usage-instructions
curl -sL https://deb.nodesource.com/setup | sudo bash -sudo apt-get install -y nodejs
This will get you a good installation of node
and npm
in the global path, visible to both your ubuntu
user and the jenkins
user.
Finally, /home/ubuntu/.npm/npm
is not an executable, but is the cached version of the npm
package; /home/ubuntu/.npm
is the per-user npm download cache.
as it says
/tmp/hudson8925730298288495807.sh: 5: /tmp/hudson8925730298288495807.sh: npm: not found
npm
isn't available in your path, so change your job to specify full path to npm
for example
/usr/local/bin/npm install
or whereever npm
is located