Re: pgAdmin in a multi DC self service context

From: Dave Page <dpage(at)pgadmin(dot)org>
To: heiko(dot)onnebrink(at)metronom(dot)com
Cc: pgAdmin Support <pgadmin-support(at)postgresql(dot)org>
Subject: Re: pgAdmin in a multi DC self service context
Date: 2019-03-29 11:20:36
Message-ID: CA+OCxozfeeATBhVWyuU7qMJrJruB4xLpMNcD4dHTYk9hKYQsYA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

Hi

On Fri, Mar 29, 2019 at 3:41 AM <heiko(dot)onnebrink(at)metronom(dot)com> wrote:

> We have developed a RESTful self service portal to provision PostgreSQL
> databases (using docker container) to different datacenter.
>
> New customer can self-register and start provisioning databases instantly.
>
>
>
> As part of the offering we plan next to provide pgAdmin in each datacenter
> in server mode.
>
>
>
> Several questions came up:
>
>
>
> 1.)
>
> How I can programmatically add new users to pgAdmin (.. and not enter them
> manually inside the web UI) ?
>
> The idea would be that inside our UI the user can request an pgAdmin
> account and our API would remotely execute inside the pgAdmin container
> (via docker exec) some command or operation that adds the user id with its
> initial password.
>

At the moment, you cannot. Please log a feature request at:
https://redmine.postgresql.org/projects/pgadmin4/issues/new

>
>
> 2.)
>
> Is there any plan to add AD integration ?
>

Well, LDAP certainly, and maybe Kerberos. See
https://redmine.postgresql.org/issues/2186

>
>
> 3.)
>
> For availability reason we support different datacenter. In each dc a
> pgAdmin instance would be running.
>
> Is there any way to sync these pgAdmin instances?
>
>
>
> From what I have seen you are using sqlite as persistence backend.
>
>
>
> Is it possible to persist the data to some alternative backend, e.g. a
> shared central PostgreSQL database?
>

No - and this would only be part of what's needed anyway. There are a
number of other things on disk. If you can point the following settings at
shared storage available from both locations, I *think* it should work:

SQLITE_PATH = '/path/to/pgadmin4.db'

SESSION_DB_PATH = '/path/to/sessions'

STORAGE_DIR = '/path/to/storage'

> In this way the user config and settings that a user enters when he is
> connected to pgAdmin in dc A would be available when he connects to pgAdmin
> in dc B,C, etc..
>
>
>
> Alternatively is it possible to copy over the pgAdmin sqlite database from
> dc A to the other dcs every night and restart pgAdmin in the other dcs in
> order to sync all configs to all other sites (assuming that dc A would be
> used as “master” site)?
>
>
>
> Thanks for your feedback and this great tool
>
> Cheers
>
> Heiko
>
> Geschäftsanschrift/Business address: METRO-nom GmbH, Metro-Straße 12,
> 40235 Duesseldorf, Germany
> Aufsichtsrat/Supervisory Board: Heiko Hutmacher (Vorsitzender/Chairman)
> Geschäftsführung/Management Board: Timo Salzsieder (Vorsitzender/CEO),
> Felix Lindemann (COO), Frank Hammerle (CFO)
> Sitz Düsseldorf, Amtsgericht Düsseldorf, HRB 18232/Registered Office
> Düsseldorf, Commercial Register of the Düsseldorf Local Court, HRB 18232
>
> Betreffend Mails von *(at)metronom(dot)com <http://metrosystems.net/>
> Die in dieser E-Mail enthaltenen Nachrichten und Anhänge sind
> ausschließlich für den bezeichneten Adressaten bestimmt. Sie können
> rechtlich geschützte, vertrauliche Informationen enthalten. Falls Sie nicht
> der bezeichnete Empfänger oder zum Empfang dieser E-Mail nicht berechtigt
> sind, ist die Verwendung, Vervielfältigung oder Weitergabe der Nachrichten
> und Anhänge untersagt. Falls Sie diese E-Mail irrtümlich erhalten haben,
> informieren Sie bitte unverzüglich den Absender und vernichten Sie die
> E-Mail.
>
> Regarding mails from *(at)metronom(dot)com <http://metrosystems.net/>
> This e-mail message and any attachment are intended exclusively for the
> named addressee. They may contain confidential information which may also
> be protected by professional secrecy. Unless you are the named addressee
> (or authorised to receive for the addressee) you may not copy or use this
> message or any attachment or disclose the contents to anyone else. If this
> e-mail was
>

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

Browse pgadmin-support by date

  From Date Subject
Next Message heiko.onnebrink 2019-03-29 11:33:46 Re: pgAdmin in a multi DC self service context
Previous Message heiko.onnebrink 2019-03-29 07:40:46 pgAdmin in a multi DC self service context