From: Arthur Zakirov <a.zakirov@postgrespro.ru>
To: Matt Zagrabelny <mzagrabe@d.umn.edu>
To: alvherre@2ndquadrant.com
Cc: pgsql-general@postgresql.org >> PG-General Mailing List <pgsql-general@postgresql.org>
Subject: Re: psql profiles?
Date: Fri, 7 Dec 2018 16:41:32 +0300
Message-ID: <3a918aca-6d16-5799-94cb-daf790128c5d@postgrespro.ru> (raw)
In-Reply-To: <CAOLfK3V1+wVqJe6x9QZqBHerb0N_D0XPGKzLpJng3AN7X+Gnkg@mail.gmail.com>
References: <CAOLfK3VvDo=mm9N_dxrYouwj4hN_izhMeaNU6gqRa9evTL7ORw@mail.gmail.com>
<20181206222318.6jolbk3oscgbvb4c@alvherre.pgsql>
<CAOLfK3V1+wVqJe6x9QZqBHerb0N_D0XPGKzLpJng3AN7X+Gnkg@mail.gmail.com>
On 07.12.2018 01:34, Matt Zagrabelny wrote:
>
>
> On Thu, Dec 6, 2018 at 4:24 PM Alvaro Herrera <alvherre@2ndquadrant.com
> <mailto:alvherre@2ndquadrant.com>> wrote:
>
> Sure, just define a pg_service.conf file.
> https://www.postgresql.org/docs/11/libpq-pgservice.html
>
>
> Thanks Alvaro!
>
> Is there any shorter version than:
>
> psql "service=foo"
>
> ?
>
> If not, I can make a shell alias that puts the "service=$@" into the
> command.
Also you can set environment variable PGSERVICE=foo in your .bashrc. Or
you can just set variable PGHOST=db-host-1.example.com. In last case you
don't need pg_service.conf file.
--
Arthur Zakirov
Postgres Professional: http://www.postgrespro.com
Russian Postgres Company
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: a.zakirov@postgrespro.ru, mzagrabe@d.umn.edu, alvherre@2ndquadrant.com
Subject: Re: psql profiles?
In-Reply-To: <3a918aca-6d16-5799-94cb-daf790128c5d@postgrespro.ru>
References: <CAOLfK3VvDo=mm9N_dxrYouwj4hN_izhMeaNU6gqRa9evTL7ORw@mail.gmail.com> <20181206222318.6jolbk3oscgbvb4c@alvherre.pgsql> <CAOLfK3V1+wVqJe6x9QZqBHerb0N_D0XPGKzLpJng3AN7X+Gnkg@mail.gmail.com> <3a918aca-6d16-5799-94cb-daf790128c5d@postgrespro.ru>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox