lib/mongrel_cluster/recipes.rb in mongrel_cluster-0.2.0 vs lib/mongrel_cluster/recipes.rb in mongrel_cluster-0.2.1

- old
+ new

@@ -4,10 +4,11 @@ set :mongrel_address, "127.0.0.1" set :mongrel_environment, "production" set :mongrel_conf, nil set :mongrel_user, nil set :mongrel_group, nil + set :mongrel_prefix, nil desc <<-DESC Configure Mongrel processes on the app server. This uses the :use_sudo variable to determine whether to use sudo or not. By default, :use_sudo is set to true. @@ -23,10 +24,11 @@ argv << "-a #{mongrel_address}" argv << "-c #{current_path}" argv << "-C #{mongrel_conf}" argv << "--user #{mongrel_user}" if mongrel_user argv << "--group #{mongrel_group}" if mongrel_group + argv << "--prefix #{mongrel_prefix}" if mongrel_prefix cmd = argv.join " " send(run_method, cmd) end desc <<-DESC @@ -41,12 +43,12 @@ desc <<-DESC Restart the Mongrel processes on the app server by starting and stopping the cluster. This uses the :use_sudo variable to determine whether to use sudo or not. By default, :use_sudo is set to true. DESC task :restart_mongrel_cluster , :roles => :app do - stop_mongrel_cluster - start_mongrel_cluster + set_mongrel_conf + send(run_method, "mongrel_rails cluster::restart -C #{mongrel_conf}") end desc <<-DESC Stop the Mongrel processes on the app server. This uses the :use_sudo variable to determine whether to use sudo or not. By default, :use_sudo is @@ -70,9 +72,9 @@ task :spinner, :roles => :app do start_mongrel_cluster end def set_mongrel_conf - set :mongrel_conf, "/etc/mongrel_cluster/#{application}.conf" unless mongrel_conf + set :mongrel_conf, "/etc/mongrel_cluster/#{application}.yml" unless mongrel_conf end end \ No newline at end of file