PG :: ConnectionBad: Failed to translate host name error after starting export DATABASE_URL = postgres: // $ (whoami)

I got this error after starting

export DATABASE_URL=postgres://$(whoami)

on the command line. Now when i run the command

$$ rake db:migrate

This is a complete mistake.

rake aborted!
PG::ConnectionBad: could not translate host name "Jillian" to address: nodename nor servname provided, or not known

Tasks: TOP => db:migrate

How can I install postgres?

PS I ran this tutorial https://devcenter.heroku.com/articles/heroku-postgresql#local-setup to configure pg for a python application, but I may have an older version of pg. I am trying to at least get postgres back, as it was before I ran this file

+4
source share
1 answer

.... And the answer you were all waiting for:

, DATABASE_URL=..., , ,

unset DATABASE_URL
+6

Source: https://habr.com/ru/post/1651596/


All Articles