Having googled it (and looked on the heroku site) - i just can't find a set for instructions for setting a new rails app's database connection to be to a basic db created for a different (earlier) app. I know there's something to do with swapping the "color" of the databases available - but i have no idea how... and links or any simple instructions massively appreciated.
ps - i gave seen this question, but it is a couple of years old, and it seems things have moved on at heroku since then.
Go into the directory you are pushing to Heroku and type the following:
heroku config:set DATABASE_URL=`heroku config:get DATABASE_URL -a other-app`
Where "other-app" is the database from the app you created earlier. For example:
heroku config:set DATABASE_URL=`heroku config:get DATABASE_URL -a running-tree-4822`
More detailed instructions are on Heroku's web site:
https://devcenter.heroku.com/articles/heroku-postgresql#sharing-heroku-postgres-between-applications
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With