Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

heroku pg:psql --app my-app fails with command not found

Environment

  • Mac OSX Maverick
  • Rails 3.2.11
  • Ruby 1.9.2p290
  • Heroku toolbelt

From my terminal:

$ heroku pg:psql --app my-app
---> Connecting to HEROKU_POSTGRESQL_CYAN_URL (DATABASE_URL)
sh: psql: command not found     
like image 473
zabumba Avatar asked Dec 15 '22 21:12

zabumba


2 Answers

This means that you don't have the psql command in your system. Try which psql to confirm. If you have installed postgres, then it means that its bin directory is not in your $PATH. If you haven't installed postgres yet, then install postgres and try again.

like image 167
hgmnz Avatar answered Dec 29 '22 00:12

hgmnz


Run brew install postgres and it should work.

like image 45
Erik Saunier Avatar answered Dec 28 '22 22:12

Erik Saunier