Schedule rake tasks on Heroku

Heroku offers a very simple and free way to schedule any tasks. This is basically an interface to cron.

To do so you first need to install the scheduler addon on Heroku:

$ heroku addons:add scheduler:standard

Once this is done, you just need to go to your dashboard, click the app you just add the addon and click on “Heroku Scheduler Standard”:

Heroku App Dashboard

Then, you can define with task to execute (rake earthquake:import in my case), and the frequency:

Heroku Sheduler Addon

Note that the minimum frequency to execute a command in 10 minutes.