I have been having a lot of troubles with Rails after upgrading to Mountain Lion.
Trying to trouble shoot these and searching for hours on the internet so far I have
Alternatively, use the Postgres app. IMO, it's the easiest and fastest way to get up and running with PostgreSQL and Rails on Mac.
For detailed instructions: http://blog.parsalabs.com/blog/2013/09/14/installing-postgresql-don-mac-os-x-and-using-it-as-your-rails-apps-database/