forked from tobi/delayed_job
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Tobias Lütke <[email protected]>
- Loading branch information
Dean Strelau
authored and
Tobias Lütke
committed
Dec 29, 2008
1 parent
c08971b
commit 825ebcf
Showing
4 changed files
with
9 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1 @@ | ||
namespace :jobs do | ||
desc "Clear the delayed_job queue." | ||
task :clear => :environment do | ||
Delayed::Job.delete_all | ||
end | ||
|
||
desc "Start a delayed_job worker." | ||
task :work => :environment do | ||
Delayed::Worker.new(:min_priority => ENV['MIN_PRIORITY'], :max_priority => ENV['MAX_PRIORITY']).start | ||
end | ||
end | ||
load 'tasks' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,15 @@ | ||
# Re-definitions are appended to existing tasks | ||
task :environment | ||
task :merb_env | ||
|
||
namespace :jobs do | ||
desc "Clear the delayed_job queue." | ||
task :clear => :merb_env do | ||
task :clear => [:merb_env, :environment] do | ||
Delayed::Job.delete_all | ||
end | ||
|
||
desc "Start a delayed_job worker." | ||
task :work => :merb_env do | ||
task :work => [:merb_env, :environment] do | ||
Delayed::Worker.new(:min_priority => ENV['MIN_PRIORITY'], :max_priority => ENV['MAX_PRIORITY']).start | ||
end | ||
end |