[SOLVED] MUP failing on deployment. Error messages not clear


#1

For the life of me, I have no idea why my app isn’t deploying now?
This is the dump of my terminal, I haven’t removed anything other than masking my IP.

I have a feeling like this is what is killing the deployment process, but I don’t know why:
curl: (7) Failed to connect to localhost port 3100: Connection refused??

I have an old version of the application deployed there, on that port, working fine!
I’ve rebuilt a big chunk of it, and am using a different dev machine to run mup deploy.
Just isn’t working for me.
It still doesn’t work even if I stop the application from running before running deploy…

I checked the mup logs but they didn’t have anything in there other than I was possibly using an old version of node in my deployment. Changing that didn’t fix the error…

Started TaskList: Deploy app 'cstrat' (linux)
[X.X.X.X] - Uploading bundle
[X.X.X.X] ✔ Uploading bundle: SUCCESS
[X.X.X.X] - Setting up Environment Variables
[X.X.X.X] ✔ Setting up Environment Variables: SUCCESS
[X.X.X.X] - Invoking deployment process
[X.X.X.X] ✘ Invoking deployment process: FAILED
	
	-----------------------------------STDERR-----------------------------------
	yp/0.10.33',
	gyp info spawn args   '-Dmodule_root_dir=/opt/cstrat/tmp/bundle/programs/server/npm/npm-bcrypt/node_modules/bcrypt',
	gyp info spawn args   '--depth=.',
	gyp info spawn args   '--no-parallel',
	gyp info spawn args   '--generator-output',
	gyp info spawn args   'build',
	gyp info spawn args   '-Goutput_dir=.' ]
	gyp info spawn make
	gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
	gyp info ok 
	npm WARN package.json meteor-dev-bundle@0.0.0 No description
	npm WARN package.json meteor-dev-bundle@0.0.0 No repository field.
	npm WARN package.json meteor-dev-bundle@0.0.0 No README data
	stop: Unknown instance: 
	  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
	                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0curl: (7) Failed to connect to localhost port 3100: Connection refused
	Latest deployment failed! Reverted back to the previous version.
	-----------------------------------STDOUT-----------------------------------
	t_lib.node: Finished
	  COPY Release/bcrypt_lib.node
	make: Leaving directory `/opt/cstrat/tmp/bundle/programs/server/npm/npm-bcrypt/node_modules/bcrypt/build'
	
	> fibers@1.0.5 install /opt/cstrat/tmp/bundle/programs/server/node_modules/fibers
	> node ./build.js
	
	`linux-x64-v8-3.14` exists; testing
	Binary is fine; exiting
	underscore@1.5.2 node_modules/underscore
	
	eachline@2.3.3 node_modules/eachline
	└── type-of@2.0.1
	
	semver@4.1.0 node_modules/semver
	
	source-map-support@0.2.8 node_modules/source-map-support
	└── source-map@0.1.32 (amdefine@0.1.0)
	
	fibers@1.0.5 node_modules/fibers
	
	chalk@0.5.1 node_modules/chalk
	├── ansi-styles@1.1.0
	├── escape-string-regexp@1.0.3
	├── supports-color@0.2.0
	├── has-ansi@0.1.0 (ansi-regex@0.2.1)
	└── strip-ansi@0.3.0 (ansi-regex@0.2.1)
	Waiting for MongoDB to initialize. (5 minutes)
	connected
	cstrat start/running, process 4801
	Waiting for 30 seconds while app is booting up
	Checking is app booted or not?
	cstrat stop/waiting
	cstrat start/running, process 4884
	----------------------------------------------------------------------------

My MUP logs:

Meteor Up: Production Quality Meteor Deployments
------------------------------------------------

[Y.Y.Y.Y] Warning: Permanently added '[Y.Y.Y.Y]:PPPP' (RSA) to the list of known hosts.
[Y.Y.Y.Y] Meteor requires Node v0.10.36 or later.
error: Forever detected script exited with code: 1
error: Script restart attempt #50
Meteor requires Node v0.10.36 or later.
error: Forever detected script exited with code: 1
error: Script restart attempt #51
Meteor requires Node v0.10.36 or later.
error: Forever detected script exited with code: 1
 >> stepping down to gid: meteoruser
 >> stepping down to uid: meteoruser

Update:

So I ran mup with the full debug mode on: DEBUG=* mup deploy
The first chunk of the error message is missing, posted it below.

There is a warning that it can’t run bcrypt in the working dir. Not sure if thats what is killing my deploy…
If I didn’t get my hair cut so short, I would be pulling it out of my head right now…

Warning: Permanently added '[Y.Y.Y.Y]:PPPP' (RSA) to the list of known hosts.
npm WARN cannot run in wd bcrypt@0.7.8 node-gyp rebuild (wd=/opt/cstrat/tmp/bundle/programs/server/npm/npm-bcrypt/node_modules/bcrypt)
gyp info it worked if it ends with ok
gyp info using node-gyp@1.0.3
gyp info using node@0.10.33 | linux | x64
gyp info spawn python
gyp info spawn args [ '/usr/lib/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/opt/cstrat/tmp/bundle/programs/server/npm/npm-bcrypt/node_modules/bcrypt/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/usr/lib/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/home/meteor/.node-gyp/0.10.33/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/home/meteor/.node-gyp/0.10.33',

#2

Ok so I managed to get it to deploy, however I don’t know what I did to fix it.

On my server I tried to upgrade node because of that weird error message saying I needed 0.10.36.

I am not too familiar with node so I found a suggestion on another website for updating node using n.

sudo npm cache clean -f
sudo npm install -g n
sudo n 0.10.36

However none of this worked, my server is still running 0.10.33 - says so when I type node -v.

After all that I tried to deploy once again and it worked…


#3

I experienced the same issues a few weeks ago and found exactly node 0.10.36 is the issue.


#4

Is it weird that when I type node -v it still shows 0.10.33??
I don’t think I did anything with those steps?

Wish I knew what actually fixed my error…


#5

Some tutorials use “nodeVersion”: “0.10.33” in the In the MUP configuration file, while it should be “nodeVersion”: “0.10.36”

It may be the case

One of my solution is to deploy to the fresh new server/host/droplet/VM


#6

I confirmed “nodeVersion”: “0.10.36” must be in mup.json
Errors will occur if incorrect version is used