Skip to content

Commit

Permalink
Updating README
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben VandenBos committed Apr 21, 2010
1 parent 43ab859 commit 8a277f9
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,9 @@ disclosure is always best.

### Schedule jobs per environment

Resque-Scheduler allows to create schedule jobs for specific envs.
The arg :rails_env (optional) can be used to determine which envs are concerned by the job:
Resque-Scheduler allows to create schedule jobs for specific envs. The arg
`rails_env` (optional) can be used to determine which envs are concerned by the
job:

create_fake_leaderboards:
cron: "30 6 * * 1"
Expand All @@ -99,13 +100,15 @@ The arg :rails_env (optional) can be used to determine which envs are concerned
rails_env: demo
description: "This job will auto-create leaderboards for our online demo"

The scheduled job create_fake_leaderboards will be created only if the variable RAILS_ENV is set to demo:
The scheduled job create_fake_leaderboards will be created only if the
environment variable `RAILS_ENV` is set to demo:

$ RAILS_ENV=demo rake resque:scheduler

NOTE: If you have added the 2 lines bellow to your Rails Rakefile
(ie: lib/tasks/resque-scheduler.rake), the rails env is loaded automatically
and you don't have to specify RAILS_ENV if the var is correctly set in environment.rb
and you don't have to specify RAILS_ENV if the var is correctly set in
environment.rb

Multiple envs are allowed, separated by commas:

Expand All @@ -117,7 +120,8 @@ Multiple envs are allowed, separated by commas:
rails_env: demo, staging, production
description: "This job will auto-create leaderboards"

NOTE2: If you specify the :rails_env arg without setting RAILS_ENV variable, the job won't be loaded.
NOTE: If you specify the `rails_env` arg without setting RAILS_ENV as an
environment variable, the job won't be loaded.

Resque-web additions
--------------------
Expand Down

0 comments on commit 8a277f9

Please sign in to comment.