Forum: Ruby on Rails Passenger restart problems

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
D3fc5887a2f39f2e0c8989d39ce5e6f9?d=identicon&s=25 Bharat Ruparel (bruparel)
on 2009-04-23 19:23
I am following the Passenger/Capistrano/Git deployment process outlined
in Chapter 28 of the Third Edition of Agile Development book. Everything
seems to work well except being able to restart my application. I am on
Ubuntu 8.10. Here is my configuration info:

1. httpd.conf file in /etc/apache2 is as follows:

LoadModule passenger_module
PassengerRuby /opt/ruby-enterprise/bin/ruby

<VirtualHost *:80>
   ServerName localhost
   DocumentRoot /home/bruparel/r_work/insurance/current/public/
   <Directory /home/bruparel/r_work/insurance/current/public>
      Order allow,deny
      Allow from all

2. Here is the Capistrano deploy.rb file:

set :application, "insurance"
set :user, "bruparel"
set :admin_runner, "bruparel"
set :domain, ''

role :app, domain
role :web, domain
role :db,  domain, :primary => true

default_run_options[:pty] = true
set :repository, "#{user}@#{domain}:git/#{application}.git"
set :deploy_to, "/home/#{user}/r_work/#{application}"

set :scm, "git"
set :branch, "master"
set :deploy_via, :remote_cache
set :scm_verbose, true
set :use_sudo, false

namespace :deploy do
  desc "Restart Application"
  task :restart do
    run "touch #{current_path}/tmp/restart.txt"

When I run cap deploy:restart, I can see the restart.txt file is being
“touched” correctly by Capistrano since the timestamp changes. However,
Passenger fails to restart my application, I have to manually restart
Apache for my app to pick up redeployed changes.

Any help would be appreciated.


This topic is locked and can not be replied to.