2

I use Nodejs 0.10 within Openshift PaaS. I have an Npm json package with dependencies such as Gulp, building tasks such as Gulp-sass, Gulp-usemin, Bower. They are launched in build action_hook script.

Logs on Jenkins show a dependency Gulp-utils' error with version: ^2.2.0, but Npm on Openshift doesn't like this character ^, also this dependency is not in my package.json, but inside the children.

npm ERR! Error: No compatible version found: gulp-util@'^2.2.0'

during downloading too, an ENOTEMPTY error:

npm ERR! error rolling back Error: ENOTEMPTY, rmdir '/var/lib/openshift/xxxxxx/app-root/runtime/repo/node_modules/gulp-bundle/node_modules/glob/test'

an ENOENT error:

npm ERR! Error: ENOENT, lstat '/var/lib/openshift/xxxxxx/app-root/runtime/repo/node_modules/gulp-notify/node_modules/gulp-util/node_modules/lodash.template/node_modules/lodash._escapestringchar/README.md'

an EEXIST error:

npm ERR! EEXIST, mkdir '/var/lib/openshift/xxxxxx/app-root/runtime/repo/node_modules/gulp-notify/node_modules/gulp-util/node_modules/lodash.template/node_modules/lodash.keys/node_modules/lodash._shimkeys' File exists, Move it away, and try again.

After the Archiving artifacts, Jenkins finished with FAILURE. Tested with Nodejs v0.10.26 but there are errors which are similar.

Luca
  • 45
  • 8

1 Answers1

0

Meybe you need upgrade your npm to the latest version. The older version of npm did not support "^" character in front of package's version. You can check npm version by issue command in console:

npm --version

By this post, the latest version of npm is 1.4.21

You can use following command to install/upgrade npm

curl -L https://npmjs.org/install.sh | sudo sh

sudo is not nessary if you are already root. If you met sh error, such as html is not a command, do the following:

wget https://npmjs.org/install.sh
chmod +x install.sh
sudo ./install.sh

Good Luck!

Nick Ma
  • 88
  • 1
  • 8