GOLF(2gg)

πŸ“¦ version 601.4.41, in ubuntu questing

πŸ’… GOLF(2gg) β€” postgresql-database

okay bestie, welcome to the Golf docs, 2gg section, and today's main character is the database page 🐘✨


✨ NAME ✨

postgresql-database β€” Golf documentation (database)


🌸 DESCRIPTION 🌸

so like. your Postgres database config file? it holds a Postgres connection string. that's the whole vibe. πŸ’–

if you wanna see every single parameter you could possibly put in there, they're all listed over at:

https://www.postgresql.org/docs/14/libpq-connect.html#LIBPQ-CONNSTRING

but ngl, most of the time you're only touching a couple of those options, like literally just this:

user=myuser password=mypwd dbname=mydb

okay so let's break down what that file is actually giving:

  • user β€” the Postgres user πŸ‘€
  • password β€” the password for that Postgres user πŸ”‘
  • dbname β€” the Postgres database name πŸ—‚οΈ

and here's the lil glow-up tip: if you're using peer-authenticated login (a.k.a. passwordless login, iykyk), then just omit password entirely. that's the situation where your Postgres user name is the exact same as your Operating System user name, and the local unix domain socket is what's doing the authentication for you. no password needed, it's giving trust fall 🫢


πŸ¦‹ SEE ALSO πŸ¦‹

  • Database
  • begin-transaction
  • commit-transaction
  • current-row
  • database-config-file
  • db-error
  • mariadb-database
  • postgresql-database
  • rollback-transaction
  • run-query
  • sqlite-database
  • See all documentation

that's the whole page, bestie β€” go forth and connect πŸ’œ

this was $VERSION, dated $DATE β€” mwah, periodt πŸŽ€βœ¨

πŸ“¦ where this page comes from