public inbox for [email protected]  
help / color / mirror / Atom feed
From: Pavy Manuel <[email protected]>
To: Ashesh Vashi <[email protected]>
To: Dave Page <[email protected]>
Cc: Khushboo Vashi <[email protected]>
Cc: [email protected] <[email protected]>
Subject: RE: disable create server
Date: Fri, 27 Mar 2020 12:41:55 +0000
Message-ID: <376C920F3015BC43A3485A86670B336C2E188641@TW-MBX-P03.cnesnet.ad.cnes.fr> (raw)
In-Reply-To: <CAG7mmox=3trG7wE0MAW9NqN3sXUGm=6SyBdpBYJOWD5cnPV-KA@mail.gmail.com>
References: <376C920F3015BC43A3485A86670B336C2E1884A3@TW-MBX-P03.cnesnet.ad.cnes.fr>
	<CAFOhELd6HRg_wTf9R5WD01ZGKgfDNB6Bfpr+qm9ZjeB4DszHLA@mail.gmail.com>
	<CA+OCxoyZhVkaADOxLSNj9v5BtMWERf37XGWqvi8XeEiPMUHRgQ@mail.gmail.com>
	<CAG7mmox=3trG7wE0MAW9NqN3sXUGm=6SyBdpBYJOWD5cnPV-KA@mail.gmail.com>


Thank you all.

I try to deploy pgadmin4 on my company but I want to manage the connections (server in pgadmin) the users can create.
So, I've found the line 84 of pgadmin/dashboard/templates/dashboard/welcome_dashboard.html to disable the link :
<a href="#" onclick="pgAdmin.Dashboard.add_new_server()">
pgAdmin saves server list per user.
You may need to keep that in mind.

Yes I’m aware of that


It seems like a reasonable request to me - for example, to stop students adding random servers to a shared instance of pgAdmin that they're only supposed to be using for coursework.
Agreed.

My need is different : I deploy pgadmin4 in an ansible role which deploy the following (inside the [ ] ) :
User  ---->  [ Apache --->  pgadmin ----> pgbouncer ]  ----->  postgresql backend
And I have a script for adding a server for a specific user which create a pool and add the server tuple in the sqlite3 db.
The benefit is :
- I can serialize the connections (some users open many, many tabs)
- users who do not close their connections are not a problem (thanks to the pgbouncer timeout)
- I can reserve some connection to the production chain
- I can monitor the pool

Since yesterday, I’ve found a (ugly) solution : in the ./pgadmin/static/js/generated/browser_nodes.js, I deactivate the Server action.

But the pretty way should be to create a dedicated profile (in addition of administrator and user).

Manuel Pavy


view thread (8+ messages)  latest in thread

reply

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 using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: RE: disable create server
  In-Reply-To: <376C920F3015BC43A3485A86670B336C2E188641@TW-MBX-P03.cnesnet.ad.cnes.fr>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox