Skip to content

Instantly share code, notes, and snippets.

@jacquescrocker
Created April 11, 2011 16:10
Show Gist options
  • Save jacquescrocker/913773 to your computer and use it in GitHub Desktop.
Save jacquescrocker/913773 to your computer and use it in GitHub Desktop.
allows resque to run on heroku
# lib/tasks/resque.rake
require 'resque/tasks'
task "resque:setup" => :environment do
ENV["VVERBOSE"] = "1" if Rails.env.development?
end
desc "Starts the heroku worker"
task "jobs:work" => :environment do
ENV["QUEUE"] = "*"
ENV["INTERVAL"] = "5"
Rake::Task["resque:setup"].invoke
Rake::Task["resque:work"].invoke
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment