I am trying to migrate a database to a new application from an existing one using pgbackups, but I have problems. I read the documentation on devilus website, but I still get errors.
I have a plugin installed for both databases and I can successfully go to the original db and copy / grab it.
$ heroku pgbackups:capture -a costrecovery --expire HEROKU_POSTGRESQL_ONYX_URL (DATABASE_URL) ----backup---> b007 ←[0KCapturing... doneB - ←[0KStoring... done
And then I go to the application directory where I want to copy db and follow the instructions given in the heroku file. The problem is that I do not know if it does not work because it is a mistake, or if it is because I do not interpret the instructions correctly, which is quite possible. First, I will list the instructions from heroku dev, and then the commands that I tried.
HEROKUS INSTRUCTIONS
$ heroku pgbackups:restore DATABASE -a target-app \ `heroku pgbackups:url -a source-app`
TEAMS I GOT
$ heroku pgbackups:restore DATABASE_URL -a boiling-reef-2060 \ > heroku pgbackups:url -a costrecovery ! Backup not found $ heroku pgbackups:restore HEROKU_POSTGRESQL_GREEN_URL -a boiling-reef-2060 \ > 'heroku pgbackups:url -a costrecovery' ! Backup not found $ heroku pgbackups:restore DATABASE -a boiling-reef-2060 \ > 'heroku pgbackups:url -a costrecovery' ! Backup not found $ heroku pgbackups:restore DATABASE_URL -a costrecovery-copy2 \ > heroku pgbackups:"https://s3.amazonaws.com/hkpgbackups/ app405411@heroku.com /b 007.dump?AWSAccessKe > yId=AKIAJFDIRYCGYNFXR4FQ&Expires=1365184330&Signature=po0wZ982Jbx%2Fkv0bKk0iv P%2 > FRWac%3D" ! Resource not found
Can someone help me with the correct syntax? Thanks
source share