From 2c00d88ededc717b6c264f7b70862c1194e24c3c Mon Sep 17 00:00:00 2001 From: Nathan Broadbent Date: Thu, 1 Sep 2011 18:45:49 +0800 Subject: [PATCH] Added 'rake cron' task that calls errbit:db:clear_resolved by default. This is for heroku users using the free database. [ci skip] --- README.md | 10 +++++++++- lib/tasks/heroku/cron.rake | 5 +++++ 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 lib/tasks/heroku/cron.rake diff --git a/README.md b/README.md index 8c3efbc..96abd74 100644 --- a/README.md +++ b/README.md @@ -98,7 +98,15 @@ for you. Checkout [Airbrake](http://airbrakeapp.com) from the guys over at heroku run rake db:seed - 4. Enjoy! + 4. If you are using a free database on Heroku, you may want to periodically clear resolved errors to free up space. + + # Install the heroku cron addon, to clear resolved errors daily: + heroku addons:add cron:daily + + # Or, clear resolved errors manually: + heroku rake errbit:db:clear_resolved + + 5. Enjoy! **Configuring LDAP authentication:** diff --git a/lib/tasks/heroku/cron.rake b/lib/tasks/heroku/cron.rake new file mode 100644 index 0000000..fab6254 --- /dev/null +++ b/lib/tasks/heroku/cron.rake @@ -0,0 +1,5 @@ +desc "This task is called by the Heroku cron add-on" +task :cron => :environment do + Rake::Task["errbit:db:clear_resolved"].invoke +end + -- libgit2 0.21.2