gitlabhq/lib/tasks/resque.rake
2012-12-26 19:56:56 +02:00

12 lines
297 B
Ruby

require 'resque/tasks'
task "resque:setup" => :environment do
Resque.after_fork do
Resque.redis.client.reconnect
end
Resque.before_fork = Proc.new { ActiveRecord::Base.establish_connection }
end
desc "Alias for resque:work (To run workers on Heroku)"
task "jobs:work" => "resque:work"