By default PostgreSQL listens on a local domain socket for security reasons, however, by adding the host: localhost line you are telling the PostgreSQL driver that you want to use TCP networking, and so it switches to TCP/IP connections on port 5432.

The fact that use use localhost to connect to the local machine is irrelevant you can put any IP address there to connect to a PostgreSQL instance anywhere on the Internet


--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/a7985685-3ac0-44a5-b360-234dccdfa227%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Previous

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 2 | next ›
Discussion Overview
grouprubyonrails-talk @
categoriesrubyonrails
postedApr 3, '16 at 4:39a
activeApr 10, '16 at 10:52a
posts2
users2
websiterubyonrails.org
irc#RubyOnRails

2 users in discussion

Mike: 1 post Padmahasa B N: 1 post

People

Translate

site design / logo © 2021 Grokbase