I would like to create a script that would make a dump of a postgresql DB on heroku and download it to my local server. I using windows server 2008 R2 and would assume that this would be activated with scheduler. On the local server installed is ruby 1.93 and chocolately (run curl on a PC).
I am assuming that the script would be a ruby file and have the commands to both create a backup and and then use a curl command to download it. The latest backup would be the only one downloaded
The commands would be something like
heroku pgbackups:capture --expire -a appname
curl -o latest.dump heroku pgbackups:url
thanks in advance