Question

Here is my gist: https://gist.github.com/AustinG08/9065353 Similar error message: https://github.com/nodejitsu/jitsu/issues/493

I clone the mean.io boilerplate. I don't see anything wrong with the package.json file. I have tried implementing what was mentioned in that similar error message but I guess I am too new. This is my first stackoverflow post. Please help.

*edit for more detail: I do a git clone of github.com/linnovate/mean - the mean.io stack. I can run it locally just fine. But I want to deploy it to my nodejitsu account. I run 'jitsu deploy' in the command line and I get what is in the gist I linked. In the scripts section of package.json I try changing "start": "node node_modules/grunt-cli/bin/grunt", to "start": "node server.js", based on that similar error message I found but to no avail, same thing happens.

Était-ce utile?

La solution

I solved it thanks to your advice, but since you never posted your package.json file I'm entering it here fur further users which may stumble across this post with the same problem:

{
"name": "mean",
"description": "MEAN - A fullStack javascript framework powered by  MongoDB, ExpressJS, AngularJS, NodeJS.",
"version": "0.1.2-2",
"private": false,
"repository": {
  "type": "git",
  "url": "https://github.com/linnovate/mean.git"
},
"engines": {
  "node": "0.10.x",
  "npm": "1.3.x"
},
"scripts": {
  "start": "node server.js",
  "test": "node node_modules/grunt-cli/bin/grunt test",
  "postinstall": "node node_modules/bower/bin/bower install"
},
"dependencies": {
  "express": "~3.4.7",
  "bower": "~1.2.8",
  "grunt-cli": "~0.1.11",
  "connect-mongo": "~0.4.0",
  "connect-flash": "~0.1.1",
  "consolidate": "~0.10.0",
  "swig": "~1.3.2",
  "mongoose": "~3.8.3",
  "passport": "~0.1.18",
  "passport-local": "~0.1.6",
  "passport-facebook": "~1.0.2",
  "passport-twitter": "~1.0.2",
  "passport-github": "~0.1.5",
  "passport-google-oauth": "~0.1.5",
  "passport-linkedin": "~0.1.3",
  "lodash": "~2.4.1",
  "forever": "~0.10.11",
  "view-helpers": "~0.1.4",
  "mean-logger": "0.0.1"
},
"devDependencies": {
  "grunt-env": "~0.4.1",
  "grunt-cli": "~0.1.11",
  "grunt-contrib-watch": "latest",
  "grunt-contrib-jshint": "latest",
  "grunt-karma": "~0.6.2",
  "grunt-nodemon": "0.2.0",
  "grunt-concurrent": "latest",
  "grunt-mocha-test": "latest",
  "karma": "~0.10.4",
  "karma-coffee-preprocessor": "~0.1.0",
  "karma-coverage": "~0.1.0",
  "karma-script-launcher": "~0.1.0",
  "karma-chrome-launcher": "~0.1.0",
  "karma-firefox-launcher": "~0.1.0",
  "karma-html2js-preprocessor": "~0.1.0",
  "karma-jasmine": "~0.1.3",
  "karma-requirejs": "~0.2.0",
  "karma-phantomjs-launcher": "~0.1.0",
  "forever": "~0.10.11",
  "supertest": "0.8.2",
  "should": "2.1.1"
},
"subdomain": "hitman666-mean2"
}

After making this change I deployed my application once more, and everything went without an error, but when I browsed it on Nodejitsu I got an error: 502 Reached max retries limit.

I realized that I don’t have a correct MongoDB connection string, and in order to change this I had to edit the file production.js which is in the config/env/ folder. I copied the MongoDB connection string from Nodejitsu’s admin dashboard (I wrote about how to set this on my blog post Getting started with Nodejitsu on Windows by deploying a MEN framework).

After this change I deployed my app again, and now everything was working, yay!

P.S. If someone is interested, the whole blog post on how I did this is here: Deploying MEAN.io to Nodejitsu from Windows machine

Autres conseils

OK! Well, I got it deployed on nodejitsu thanks to help from the #node.js channel. The gist of it was I had to move all grunt, karma, and forever dependencies to my devDependencies in the package.json file and change my start to "node server".

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top