node.js - npm ERR! EEXIST - Not able to deploy a SailsJS app to Openshift -


i new openshift , sailsjs

any pointer move forward welcome.

i have created simple sails app e.g. sails new myapp, , followed openshift deployment instruction here

package.json

in package.json have tried both node app.js , sails lift start app.

  "scripts": {     "debug": "node debug app.js",     "start": "node app.js"   },   "dependencies": {     "ejs": "2.3.4",     "grunt": "0.4.5",     "grunt-bower": "^0.21.2",     "grunt-bower-task": "^0.3.4",     "grunt-cli": "^1.2.0",     "grunt-contrib-clean": "0.6.0",     "grunt-contrib-coffee": "0.13.0",     "grunt-contrib-concat": "0.5.1",     "grunt-contrib-copy": "0.5.0",     "grunt-contrib-cssmin": "0.9.0",     "grunt-contrib-jst": "0.6.0",     "grunt-contrib-less": "1.1.0",     "grunt-contrib-uglify": "0.7.0",     "grunt-contrib-watch": "0.5.3",     "grunt-sails-linker": "~0.10.1",     "grunt-sync": "0.2.4",     "include-all": "~0.1.6",     "rc": "1.0.1",     "sails": "~0.12.3",     "sails-disk": "~0.10.9"   },   "name": "myapp",   "private": true,   "version": "0.0.0",   "description": "a sails application",   "keywords": [],   "main": "app.js",   "repository": {     "type": "git",     "url": "git://github.com/joel/myapp.git"   },   "author": "joel",   "license": "" } 

git push openshift

remote: npm err! eexist, open '/var/lib/openshift/574f48527628e1bce8000273/.npm/68d71095-273-npm-lodash-2-4-2-package-tgz.lock' remote: file exists: /var/lib/openshift/574f48527628e1bce8000273/.npm/68d71095-273-npm-lodash-2-4-2-package-tgz.lock remote: move away, , try again.  remote:  remote: npm err! system linux 2.6.32-573.12.1.el6.x86_64 remote: npm err! command "node" "/opt/rh/nodejs010/root/usr/bin/npm" "install" "-d" remote: npm err! cwd /var/lib/openshift/574f48527628e1bce8000273/app-root/runtime/repo remote: npm err! node -v v0.10.35 remote: npm err! npm -v 1.4.28 remote: npm err! path /var/lib/openshift/574f48527628e1bce8000273/.npm/68d71095-273-npm-lodash-2-4-2-package-tgz.lock remote: npm err! code eexist remote: npm err! errno 47 remote: npm info preuninstall reportback@0.1.9 remote: npm info uninstall reportback@0.1.9 remote: npm info postuninstall reportback@0.1.9 remote: npm info preuninstall merge-defaults@0.2.1 remote: npm info uninstall merge-defaults@0.2.1 remote: npm info postuninstall merge-defaults@0.2.1 remote: npm info preuninstall sails-stringfile@0.3.2 remote: npm info uninstall sails-stringfile@0.3.2 remote: npm info postuninstall sails-stringfile@0.3.2 remote: npm info preuninstall sails-generate@0.13.0 remote: npm info uninstall sails-generate@0.13.0 remote: npm info postuninstall sails-generate@0.13.0 remote: npm info preuninstall sails@0.12.3 remote: npm info uninstall sails@0.12.3 remote: npm info postuninstall sails@0.12.3 remote: npm err! not ok code 0 remote: error occurred executing 'gear postreceive' (exit code: 47) remote: error message: client_error: failed execute: 'control build' /var/lib/openshift/574f48527628e1bce8000273/nodejs remote:  remote: more details problem, try running command again '--trace' option. ssh://574f48527628e1bce8000273@myapp.rhcloud.com/~/git/myapp.git    cdc73e6..df77e95  head -> master 

what command should try run --trace?

rhc tail -a myapp

debug: starting child process 'node app.js' debug: sending sigterm child... debug: running node-supervisor debug:   program 'app.js' debug:   --watch '/var/lib/openshift/574f48527628e1bce8000273/app-root/data/.nodewatch' debug:   --ignore 'undefined' debug:   --extensions 'node|js|coffee' debug:   --exec 'node' debug: starting child process 'node app.js' debug: watching directory '/var/lib/openshift/574f48527628e1bce8000273/app-root/data/.nodewatch' changes. run app using `node app.js`, need have version of `sails` installed in same directory app. that, run `npm install sails` alternatively, if have sails installed globally (i.e. did `npm install -g sails`), can use `sails lift`. when run `sails lift`, app still use local `./node_modules/sails` dependency if exists, if doesn't, app run global sails instead! debug: program node app.js exited code 0 debug: starting child process 'node app.js' run app using `node app.js`, need have version of `sails` installed in same directory app. that, run `npm install sails` alternatively, if have sails installed globally (i.e. did `npm install -g sails`), can use `sails lift`. when run `sails lift`, app still use local `./node_modules/sails` dependency if exists, if doesn't, app run global sails instead! debug: program node app.js exited code 0 

the blocker seemed be:

remote: file exists: /var/lib/openshift/574f48527628e1bce8000273/.npm/68d71095-273-npm-lodash-2-4-2-package-tgz.lock 

these steps helps me move forward

rhc ssh -a myapp  cd .npm rm 68d71095-273-npm*  

then local machine, deploy again

git push 

Popular posts from this blog

php - How should I create my API for mobile applications (Needs Authentication) -

5 Reasons to Blog Anonymously (and 5 Reasons Not To)

Google AdWords and AdSense - A Dynamic Small Business Marketing Duo