Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hgW8A-0006qV-Ia for pgadmin-hackers@arkaria.postgresql.org; Thu, 27 Jun 2019 15:16:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hgW89-0003KR-D0 for pgadmin-hackers@arkaria.postgresql.org; Thu, 27 Jun 2019 15:16:09 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hgW89-0003KK-2g for pgadmin-hackers@lists.postgresql.org; Thu, 27 Jun 2019 15:16:09 +0000 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hgW85-0006aQ-2L for pgadmin-hackers@lists.postgresql.org; Thu, 27 Jun 2019 15:16:07 +0000 Received: by mail-wm1-x341.google.com with SMTP id u8so6069837wmm.1 for ; Thu, 27 Jun 2019 08:16:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pgadmin.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=NXMbSJnz6d2NZQGeyIP7APVI/mAojTx4YO6hV8Fy/6s=; b=foIvpVq25QTb+zD7VlSTI+YZH2aqvJdh5ZjExT9xUeHBUpLDqd4f/aXAmAX36FpP6C 7XbUiex58mz7yWdall5s5bVeX9uqseiVc31+fVEUXT0oRDaT36YvGafs1tHhhSQ2dMhu UxFr2+nlOz9V6EqpQVn8xUEcowMGyUkA2AtYdhEOgO8vkwzT/bqTp3uPgTZv9ZhIdrdT wJAxQma77MVPbugD8EsPInTASqS8vZAna0RkGdxyUq20aFZMr0OaYjzcBjfRh/oYAaAP 0io54ZCRIGXUf0TaxYXgQKt37qaEQPYrhtB3n2E/pBRHbZbdeC1K5GE5wW5BVU5eKzSJ w5ow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=NXMbSJnz6d2NZQGeyIP7APVI/mAojTx4YO6hV8Fy/6s=; b=AapYhdrJ50kpBW2CBfZs0a7HddU0JZYKZ01KBE/yJf52xp03DEqfznT6iJ5fUzZ3fQ l0mxDGS5PchwL7s9F7jGEKlPIrwkE1EYuCUFAyV87FbJm94rTGGCRa4dNqc1X8raGe9v LW5O/Ttb4ByPxu7qt4co96ydm3X93wFEP4nzgMuL0Us2WITpSBfublkzzEFtmnKJYUVf hah47Gtt/nkTmdMCdMlPU49k6/gGfi/nmMXgIXCRpJiYIHYR7FRlJiBXYDKzg+Ryco+O efAe9AeJGzxrThyUOwbiXnOmf+ALaRzPM5ApQS+seiFbn6ckg3e8xEWf31KVHtHiZ6Su RNlg== X-Gm-Message-State: APjAAAVBR5jM44xm56End/7Uzqfsw2C4jMRrrLB8kPmYsFI5AFJoy1ig FVGkaG/unes8QQo0FKtxUL2WUl0YiEJvjX8xszeLGQ== X-Google-Smtp-Source: APXvYqwNEYjHTT7J5hFEX7ivV03wxT8wFL5oCxf6fJdJRdaA/HsNHd9BxhEoVt2s9AXdFK4xrnZ1QRHy4OeQs+0C+4Y= X-Received: by 2002:a7b:cc16:: with SMTP id f22mr3515182wmh.115.1561648563610; Thu, 27 Jun 2019 08:16:03 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Dave Page Date: Thu, 27 Jun 2019 11:15:52 -0400 Message-ID: Subject: Re: passwords enabled by default To: Andrew Coleman Cc: pgadmin-hackers , Syed Fahar Abbas Content-Type: multipart/alternative; boundary="000000000000e6055f058c4fa381" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --000000000000e6055f058c4fa381 Content-Type: text/plain; charset="UTF-8" Fahar, can you verify that the Password File option works as expected (or not) in a non-containerised environment? It should *not* require PGPASSFILE to be set (because that's basically what it should be doing for us). Thanks. On Thu, Jun 27, 2019 at 8:27 AM Andrew Coleman wrote: > Recently, while testing my changes to entrypoint.sh in Docker, I noticed > that you cannot import or export passwords via the servers.json file. You > can get around this by setting the PassFile option in servers.json, but > that still doesn't work correctly. For me to make this work, I had to also > set the `PGPASSFILE` to the full path location of the pgpass file generated > for me by Helm. > > To clarify, I know how many servers I want to connect to and how to find > their passwords in Kubernetes via their secret, and I use Helm to stitch > all of that together into a pgpass file that psql and pgadmin4 can use to > connect to the servers without user intervention. > > The presence of the pgpass file and the reference to that file in the > servers.json was not enough to allow pgadmin4 to connect to the servers, I > also had to set `PGPASSFILE` in my Helm chart to make this work. > > This seems like another good ticket, no? I know where to add them and I'll > put a patch in place, but I could sure use a little bit of guidance on the > copy portion of the documentation. I know why it works for me, but would > anyone conceivably use this in a non-Dockerized deployment? > > Thanks, > Andrew > -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company --000000000000e6055f058c4fa381 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Fahar, can you verify that the Password File option w= orks as expected (or not) in a non-containerised environment? It should *no= t* require PGPASSFILE to be set (because that's basically what it shoul= d be doing for us).

Thanks.

On Thu, Jun 27, 2019 at= 8:27 AM Andrew Coleman <pengu= incoder@gmail.com> wrote:
Recently, while testing my changes t= o entrypoint.sh in Docker, I noticed that you cannot import or export passw= ords via the servers.json file. You can get around this by setting the Pass= File option in servers.json, but that still doesn't work correctly. For= me to make this work, I had to also set the `PGPASSFILE` to the full path = location of the pgpass file generated for me by Helm.

<= div>To clarify, I know how many servers I want to connect to and how to fin= d their passwords in Kubernetes via their secret, and I use Helm to stitch = all of that together into a pgpass file that psql and pgadmin4 can use to c= onnect to the servers without user intervention.

T= he presence of the pgpass file and the reference to that file in the server= s.json was not enough to allow pgadmin4 to connect to the servers, I also h= ad to set `PGPASSFILE` in my Helm chart to make this work.

This seems like another good ticket, no? I know where to add them = and I'll put a patch in place, but I could sure use a little bit of gui= dance on the copy portion of the documentation. I know why it works for me,= but would anyone conceivably use this in a non-Dockerized deployment?

Thanks,
Andrew


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

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL = Company
--000000000000e6055f058c4fa381--