lib/capistrano/node-deploy.rb in capistrano-node-deploy-1.2.2 vs lib/capistrano/node-deploy.rb in capistrano-node-deploy-1.2.3
- old
+ new
@@ -37,11 +37,11 @@
<<EOD
#!upstart
description "#{application} node app"
author "capistrano"
-start on (filesystem and net-device-up IFACE=lo)
+start on runlevel [2345]
stop on shutdown
respawn
respawn limit 99 5
@@ -55,9 +55,10 @@
namespace :node do
desc "Check required packages and install if packages are not installed"
task :install_packages do
run "mkdir -p #{shared_path}/node_modules"
run "cp #{release_path}/package.json #{shared_path}"
+ run "cp #{release_path}/npm-shrinkwrap.json #{shared_path}"
run "cd #{shared_path} && npm install #{(node_env == 'production') ? '--production' : ''} --loglevel warn"
run "ln -s #{shared_path}/node_modules #{release_path}/node_modules"
end
task :check_upstart_config do