Fixed multicoops and resque rake tasks.

This commit is contained in:
Benjamin Meichsner 2013-01-07 13:44:46 +01:00
parent 0364562273
commit 1fe141175c
2 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ namespace :multicoops do
task_to_run = ARGV[1]
FoodsoftConfig.each_coop do |coop|
puts "Run '#{task_to_run}' for #{coop}"
Rake::Task[task_to_run].invoke
Rake::Task[task_to_run].execute
end
end
@ -14,7 +14,7 @@ namespace :multicoops do
task_to_run = ARGV[1]
FoodsoftConfig.select_foodcoop ENV['FOODCOOP']
puts "Run '#{task_to_run}' for #{ENV['FOODCOOP']}"
Rake::Task[task_to_run].invoke
Rake::Task[task_to_run].execute
end
end
end

View File

@ -8,7 +8,7 @@ def run_worker(queue, count = 1)
count.times {
## Using Kernel.spawn and Process.detach because regular system() call would
## cause the processes to quit when capistrano finishes
pid = spawn(env_vars, "rake resque:work", ops)
pid = spawn(env_vars, "bundle exec rake resque:work", ops)
Process.detach(pid)
}
end