More capistrano fixes
authorWard Vandewege <ward@clinicalfuture.com>
Tue, 15 Jan 2013 22:22:56 +0000 (17:22 -0500)
committerWard Vandewege <ward@clinicalfuture.com>
Tue, 15 Jan 2013 22:22:56 +0000 (17:22 -0500)
Gemfile
Gemfile.lock
config/deploy.rb

diff --git a/Gemfile b/Gemfile
index 67b74a9f8a7cc7a8dc79757d7f06dbc337c24893..9fa235c5e022d15f40c7851606ab3e370bd0ae1e 100644 (file)
--- a/Gemfile
+++ b/Gemfile
@@ -39,3 +39,5 @@ gem 'jquery-rails'
 gem 'rvm-capistrano', :group => :test
 
 gem 'acts_as_api'
+
+gem 'passenger', :group => :production
index b081b16792a6ec11a0424a0ab94e1621e3227dfa..0870fce8872d21577075dae54ef64b9fc3313c6d 100644 (file)
@@ -48,9 +48,11 @@ GEM
       coffee-script-source
       execjs
     coffee-script-source (1.4.0)
+    daemon_controller (1.1.0)
     erubis (2.7.0)
     execjs (1.4.0)
       multi_json (~> 1.0)
+    fastthread (1.0.7)
     highline (1.6.15)
     hike (1.2.1)
     i18n (0.6.1)
@@ -72,9 +74,14 @@ GEM
     net-ssh (2.6.3)
     net-ssh-gateway (1.1.0)
       net-ssh (>= 1.99.1)
+    passenger (3.0.19)
+      daemon_controller (>= 1.0.0)
+      fastthread (>= 1.0.1)
+      rack
+      rake (>= 0.8.1)
     pg (0.14.1)
     polyglot (0.3.3)
-    rack (1.3.8)
+    rack (1.3.9)
     rack-cache (1.2)
       rack (>= 0.4)
     rack-mount (0.8.3)
@@ -135,6 +142,7 @@ DEPENDENCIES
   coffee-rails (~> 3.1.1)
   jquery-rails
   json
+  passenger
   pg
   rails (= 3.1.5)
   rvm-capistrano
index 9b70e5f612baf00e2f3bb52b950956866da1204d..171ee3495353d18bd577c88b4f7e20d1867bc8b4 100644 (file)
@@ -49,11 +49,13 @@ namespace :deploy do
     # This is used by the lib/add_debug_info.rb middleware, which injects it in the
     # environment.
     run "cd #{release_path}; /usr/bin/git rev-parse HEAD > #{release_path}/git-commit.version"
+    # make sure to symlink the vendor bundle. Cf. http://gembundler.com/rationale.html
+    run "cd #{release_path}; ln -s #{shared_path}/vendor_bundle #{release_path}/vendor/bundle"
   end
 
   # desc "Install new gems if necessary"
   task :bundle_install, :roles => :app,  :except => { :no_release => true } do
-    run "cd #{release_path} && bundle install --local"
+    run "cd #{release_path} && bundle install --deployment"
   end
 
   desc "Restarting mod_rails with restart.txt"