When I run the rake db:migrate or run the rails s command, I get the same error:
rake db:migrate
rails s
Error : could not connect to server: No such file or
When I run into this error, my Postgres server was actually listening on a different port (5433) and not 5432. To solve this, add
port: 5433
to your database.yml file to instruct rails to use the same
database.yml