Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> libpq normally connects to a unix socket by being given 'localhost' as the hostname or no hostname at all.

'localhost' for a unix socket doesn't sound right. 'localhost' is a specific network address and has a default configuration in pg_hba.conf (127.0.0.1) for itself. It's different to the 'local' entry in pg_hba.conf that's specifically for unix sockets.

And yeah, the field validation in the IDE required some kind of value in the hostname field, and wouldn't take a path (ie /var/...etc), so no kind of fallback behaviour seemed workable. :(



localhost as unix socket shortcut is actually MySQL behavior: https://dev.mysql.com/doc/c-api/8.4/en/mysql-real-connect.ht...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: