I am running my development on Ubuntu 11.10, and RubyMine
Here is my development settings for the database.yml: which RubyMine created for me
develop
You can go to your /var/lib/pgsql/data/pg_hba.conf file and add trust in place of Ident It worked for me.
local all all trust
host all 127.0.0.1/32 trust
For further details refer to this issue Ident authentication failed for user
I also faced this same issue while working in my development environment, the problem was that I left host: localhost commented out in the config/database.yml file.
So my application could not connect to the PostgreSQL database, simply uncommenting it solved the issue.
development:
<<: *default
database: database_name
username: database_username
password: database_password
host: localhost
That's all.
I hope this helps