Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I connect to my heroku shared database for postgresql?

I have pulled the SHARED_DATABASE_URL from heroku config

SHARED_DATABASE_URL => postgres://username:[email protected]/db_name

I am using pgAdmin to try to connect to it but it keeps on timing out. Do I need to specify a port? What am i missing?

like image 580
Kamilski81 Avatar asked Nov 30 '22 14:11

Kamilski81


2 Answers

You can use this command to connect to psql.

heroku pg:psql

like image 103
manish_s Avatar answered Dec 04 '22 05:12

manish_s


If you are happy to change to postgres 9.1 you can use the newly launched development database, which permits connections via normal postgres tools. Read more at https://postgres.heroku.com/blog/past/2012/4/26/heroku_postgres_development_plan/

like image 23
John Beynon Avatar answered Dec 04 '22 05:12

John Beynon