forked from ddollar/heroku_backup_task
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of git://github.com/ddollar/heroku_backup_task
- Loading branch information
Showing
1 changed file
with
2 additions
and
47 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,3 @@ | ||
# heroku\_backup\_task | ||
# This project has a new maintainer | ||
|
||
## Description | ||
|
||
A simple helper to automate your [Heroku](http://heroku.com) app [backups](http://addons.heroku.com/pgbackups) | ||
|
||
## Installation | ||
|
||
# Gemfile | ||
gem "heroku_backup_task" | ||
|
||
# Rakefile | ||
require "heroku_backup_task/tasks" | ||
task :cron => :heroku_backup | ||
|
||
# Rakefile (alternative) | ||
require "heroku_backup_task" | ||
task :cron do | ||
# other code here | ||
HerokuBackupTask.execute | ||
end | ||
|
||
Make sure you install the pgbackups addon | ||
|
||
heroku addons:add pgbackups:basic | ||
|
||
## Configuration | ||
|
||
By default, `heroku_backup_task` will back up `DATABASE_URL`. You can change this with: | ||
|
||
heroku config:add HEROKU_BACKUP_DATABASES="SOME_DATABASE_URL,OTHER_DATABASE_URL" | ||
|
||
## Usage | ||
|
||
### NOTE: `heroku_backup_task` will expire your oldest backup to make room for a new backup if necessary. | ||
|
||
Set up cron on your application with | ||
|
||
heroku addons:add cron:daily | ||
|
||
You will see something like this in your cron logs | ||
|
||
[Thu Nov 18 12:59:56 -0500 2010] starting heroku backup task | ||
[Thu Nov 18 12:59:57 -0500 2010] backing up: DATABASE_URL | ||
|
||
## License | ||
|
||
MIT | ||
https://github.com/joemsak/heroku_backup_task |