Re: pgAdmin in a multi DC self service context

From: <heiko(dot)onnebrink(at)metronom(dot)com>
To: <dpage(at)pgadmin(dot)org>
Cc: <pgadmin-support(at)postgresql(dot)org>
Subject: Re: pgAdmin in a multi DC self service context
Date: 2019-03-29 11:33:46
Message-ID: B1B0D94B-EBAF-4C5B-9ED1-A6452249BCED@metronom.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:Menlo;
panose-1:2 11 6 9 3 8 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
p.gmail-p1, li.gmail-p1, div.gmail-p1
{mso-style-name:gmail-p1;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.gmail-s1
{mso-style-name:gmail-s1;}
span.gmail-apple-converted-space
{mso-style-name:gmail-apple-converted-space;}
span.gmail-m9021567724258148063msohyperlink
{mso-style-name:gmail-m_9021567724258148063msohyperlink;}
span.EmailStyle23
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="DE" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-US">Thanks for fast feedback..<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">One point not clear.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">would it be OK just to copy the .db file from “master” location to “slave” locations:<o:p></o:p></span></p>
<p class="gmail-p1" style="margin:0cm;margin-bottom:.0001pt;background:#224FBC"><span class="gmail-s1"><span lang="EN-US" style="font-size:10.0pt;font-family:Menlo;color:white">SQLITE_PATH = '/path/to/pgadmin4.db'</span></span><span lang="EN-US" style="font-size:10.0pt;font-family:Menlo;color:white"><o:p></o:p></span></p>
<p class="MsoNormal" style="font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal">
<span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">I do not need to preserve user dumps or session states.. just the ability to connect to a standby site (in case master site goes down) and find all server configs and settings in slave locations like they were entered
on master site?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>&nbsp;</o:p></span></p>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:12.0pt;color:black">From: </span></b><span style="font-size:12.0pt;color:black">Dave Page &lt;dpage(at)pgadmin(dot)org&gt;<br>
<b>Date: </b>Friday, 29. March 2019 at 12:20<br>
<b>To: </b>&quot;Onnebrink, Heiko&quot; &lt;heiko(dot)onnebrink(at)metronom(dot)com&gt;<br>
<b>Cc: </b>pgAdmin Support &lt;pgadmin-support(at)postgresql(dot)org&gt;<br>
<b>Subject: </b>Re: pgAdmin in a multi DC self service context<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<div>
<div>
<div>
<p class="MsoNormal">Hi<o:p></o:p></p>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<div>
<div>
<p class="MsoNormal">On Fri, Mar 29, 2019 at 3:41 AM &lt;<a href="mailto:heiko(dot)onnebrink(at)metronom(dot)com">heiko(dot)onnebrink(at)metronom(dot)com</a>&gt; wrote:<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">We have developed a RESTful self service portal to provision PostgreSQL databases (using docker container) to different datacenter.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">New customer can self-register and start provisioning databases instantly.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">As part of the offering we plan next to provide pgAdmin in each datacenter in server mode.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Several questions came up:</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">1.)</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">How I can programmatically add new users to pgAdmin (.. and not enter them manually inside the web UI) ?</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">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.</span><o:p></o:p></p>
</div>
</div>
</blockquote>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">At the moment, you cannot. Please log a feature request at:&nbsp;<a href="https://redmine.postgresql.org/projects/pgadmin4/issues/new">https://redmine.postgresql.org/projects/pgadmin4/issues/new</a><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">&nbsp;<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">2.)
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Is there any plan to add AD integration ?</span><o:p></o:p></p>
</div>
</div>
</blockquote>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">Well, LDAP certainly, and maybe Kerberos. See&nbsp;<a href="https://redmine.postgresql.org/issues/2186">https://redmine.postgresql.org/issues/2186</a><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">&nbsp;<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">3.)</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">For availability reason we support different datacenter. In each dc a pgAdmin instance would be running.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Is there any way to sync these pgAdmin instances?</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">From what I have seen you are using sqlite as persistence backend.
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Is it possible to persist the data to some alternative backend, e.g. a shared central PostgreSQL database?</span><o:p></o:p></p>
</div>
</div>
</blockquote>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="MsoNormal">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:<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<div>
<p class="gmail-p1" style="margin:0cm;margin-bottom:.0001pt;background:#224FBC;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal">
<span class="gmail-apple-converted-space"><span style="font-size:10.0pt;font-family:Menlo;color:white">&nbsp; &nbsp;&nbsp;</span></span><span class="gmail-s1"><span style="font-size:10.0pt;font-family:Menlo;color:white">SQLITE_PATH = '/path/to/pgadmin4.db'</span></span><span style="font-size:10.0pt;font-family:Menlo;color:white"><o:p></o:p></span></p>
<p class="gmail-p1" style="margin:0cm;margin-bottom:.0001pt;background:#224FBC;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal">
<span class="gmail-apple-converted-space"><span style="font-size:10.0pt;font-family:Menlo;color:white">&nbsp; &nbsp;
</span></span><span class="gmail-s1"><span style="font-size:10.0pt;font-family:Menlo;color:white">SESSION_DB_PATH = '/path/to/sessions'</span></span><span style="font-size:10.0pt;font-family:Menlo;color:white"><o:p></o:p></span></p>
<p class="gmail-p1" style="margin:0cm;margin-bottom:.0001pt;background:#224FBC;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal">
<span class="gmail-apple-converted-space"><span style="font-size:10.0pt;font-family:Menlo;color:white">&nbsp; &nbsp;
</span></span><span class="gmail-s1"><span style="font-size:10.0pt;font-family:Menlo;color:white">STORAGE_DIR = '/path/to/storage'</span></span><span style="font-size:10.0pt;font-family:Menlo;color:white"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal">&nbsp;<o:p></o:p></p>
</div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm">
<div>
<div>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">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..</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">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)?</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Thanks for your feedback and this great tool
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Cheers</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span lang="EN-US">Heiko</span><o:p></o:p></p>
</div>
<p><span style="font-size:9.0pt;font-family:&quot;Verdana&quot;,sans-serif">Geschäftsanschrift/Business address: METRO-nom GmbH, Metro-Straße 12, 40235 Duesseldorf, Germany<br>
Aufsichtsrat/Supervisory Board: Heiko Hutmacher (Vorsitzender/Chairman)<br>
Geschäftsführung/Management Board:&nbsp;Timo Salzsieder (Vorsitzender/CEO), Felix Lindemann (COO), Frank Hammerle (CFO)<br>
Sitz Düsseldorf, Amtsgericht Düsseldorf, HRB 18232/Registered Office Düsseldorf, Commercial Register of the Düsseldorf Local Court, HRB 18232</span><span style="font-family:&quot;Verdana&quot;,sans-serif"><o:p></o:p></span></p>
<p><span style="font-size:9.0pt;font-family:&quot;Verdana&quot;,sans-serif">Betreffend Mails von *@<span class="gmail-m9021567724258148063msohyperlink"><span style="color:#0563C1"><a href="http://metrosystems.net/" target="_blank"><span style="color:#0563C1">metronom.com</span></a></span></span><br>
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.</span><span style="font-family:&quot;Verdana&quot;,sans-serif"><o:p></o:p></span></p>
<p><span lang="EN-US" style="font-size:9.0pt;font-family:&quot;Verdana&quot;,sans-serif">Regarding mails from *@<span class="gmail-m9021567724258148063msohyperlink"><span style="color:#0563C1"><a href="http://metrosystems.net/" target="_blank"><span style="color:#0563C1">metronom.com</span></a></span></span><br>
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</span><span style="font-family:&quot;Verdana&quot;,sans-serif"><o:p></o:p></span></p>
</div>
</blockquote>
</div>
<p class="MsoNormal"><br clear="all">
<o:p></o:p></p>
<div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
</div>
<p class="MsoNormal">-- <o:p></o:p></p>
<div>
<p class="MsoNormal">Dave Page<br>
Blog: <a href="http://pgsnake.blogspot.com" target="_blank">http://pgsnake.blogspot.com</a><br>
Twitter: @pgsnake<br>
<br>
EnterpriseDB UK: <a href="http://www.enterprisedb.com" target="_blank">http://www.enterprisedb.com</a><br>
The Enterprise PostgreSQL Company<o:p></o:p></p>
</div>
</div>
</div>
</div>
</div>
<span style="font-family: Verdana;"><span><p><span style="font-size:9.0pt;font-family:&quot;Verdana&quot;,sans-serif;mso-bidi-font-family:
Arial">Geschäftsanschrift/Business address: METRO-nom GmbH, Metro-Straße 12,
40235 Duesseldorf, Germany<br>
Aufsichtsrat/Supervisory Board: Heiko Hutmacher (Vorsitzender/Chairman)<br>
Geschäftsführung/Management Board:&nbsp;Timo Salzsieder (Vorsitzender/CEO),
Felix Lindemann (COO), Frank Hammerle (CFO)<br>
Sitz Düsseldorf, Amtsgericht Düsseldorf, HRB 18232/Registered Office
Düsseldorf, Commercial Register of the Düsseldorf Local Court, HRB 18232</span><span style="font-size:10.0pt;font-family:&quot;Verdana&quot;,sans-serif;mso-bidi-font-family:
Arial"><o:p></o:p></span></p><p><span style="font-size:9.0pt;font-family:&quot;Verdana&quot;,sans-serif;mso-bidi-font-family:
Arial">Betreffend Mails von *@<span class="MsoHyperlink"><span style="color:#0563C1"><a href="http://metrosystems.net/" target="_blank"><span style="color:#0563C1">metronom.com</span></a></span></span><br>
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.</span><span style="font-size:10.0pt;
font-family:&quot;Verdana&quot;,sans-serif;mso-bidi-font-family:Arial"><o:p></o:p></span></p><p>

<span lang="EN-US" style="font-size:9.0pt;line-height:107%;font-family:&quot;Verdana&quot;,sans-serif;
mso-fareast-font-family:Calibri;mso-fareast-theme-font:minor-latin;mso-bidi-font-family:
&quot;Times New Roman&quot;;mso-bidi-theme-font:minor-bidi;mso-ansi-language:EN-US;
mso-fareast-language:EN-US;mso-bidi-language:AR-SA">Regarding mails from *@<span class="MsoHyperlink"><span style="color:#0563C1"><a href="http://metrosystems.net/" target="_blank"><span style="color:#0563C1">metronom.com</span></a></span></span><br>
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</span></p></span></span></body>
</html>

Attachment Content-Type Size
unknown_filename text/html 18.1 KB

In response to

Responses

Browse pgadmin-support by date

  From Date Subject
Next Message Dave Page 2019-03-29 11:36:50 Re: pgAdmin in a multi DC self service context
Previous Message Dave Page 2019-03-29 11:20:36 Re: pgAdmin in a multi DC self service context