Re: mild modification to pg_dump

From: marcelo <marcelo(dot)nicolet(at)gmail(dot)com>
To: Scott Mead <scottm(at)openscg(dot)com>
Cc: PostgreSQL General <pgsql-general(at)postgresql(dot)org>
Subject: Re: mild modification to pg_dump
Date: 2017-11-17 21:56:45
Message-ID: d3705b2a-8b4f-b1e0-6585-466766070e48@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Thank you, Scott.
That's happening me because incomplete docs reading.
Truly, I'm catched in a very big app, so I have no time to read all the
docs.

On 17/11/17 18:31, Scott Mead wrote:
>
> On Fri, Nov 17, 2017 at 4:06 PM, marcelo <marcelo(dot)nicolet(at)gmail(dot)com
> <mailto:marcelo(dot)nicolet(at)gmail(dot)com>> wrote:
>
> I need to "emulate" the pg_dump code because the password prompt.
> Years ago I write a program (for the QnX environment) that catched
> some prompt and emulates the standard input. I don't like to do
> that again.
>
>
> pg_dump can use an environment variable "PGPASSWORD" upon execution
> (actually, all libpq programs can).  You could have a wrapper that
> sets the environment variable and then executes pg_dump, this would
> get you around that prompt.  Similarly, you could use the .pgpass file.
>
> https://www.postgresql.org/docs/9.5/static/libpq-envars.html
> https://www.postgresql.org/docs/9.5/static/libpq-pgpass.html
>
> --Scott
>
>
>
> On 17/11/17 17:23, John R Pierce wrote:
>
> On 11/17/2017 12:19 PM, marcelo wrote:
>
> Sorry, I was not exact.
> I don't need nor like to change pg_dump. Rather, based on
> pg_dump code, I need to develop a daemon which can receive
> a TCP message (from a privileged app) containing some
> elements: the database to dump, the user under which do
> that, and his password. (My apps are using that same data,
> of course, encripted to the common users).
>
>
>
> I would just fork pg_dump to do the actual dump rather than
> try and incorporate its source code into your app.
>
>
>
>
>
> --
> Sent via pgsql-general mailing list (pgsql-general(at)postgresql(dot)org
> <mailto:pgsql-general(at)postgresql(dot)org>)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
> <http://www.postgresql.org/mailpref/pgsql-general>
>
>
>
>
> --
> --
> Scott Mead
> Sr. Architect
> /OpenSCG <http://openscg.com>/
> http://openscg.com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message marcelo 2017-11-17 21:58:43 Re: mild modification to pg_dump
Previous Message Scott Mead 2017-11-17 21:31:54 Re: mild modification to pg_dump