Re: SHOW_GRAVATAR_IMAGE ignored

From: mail(at)mcnesium(dot)com
To: Dave Page <dpage(at)pgadmin(dot)org>
Cc: "pgadmin-support lists(dot)postgresql(dot)org" <pgadmin-support(at)lists(dot)postgresql(dot)org>
Subject: Re: SHOW_GRAVATAR_IMAGE ignored
Date: 2018-11-19 12:46:05
Message-ID: 8a9743e36f03e0572b0a5e73e82d3787@mcnesium.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

Ok cool, so I created a file `config_local.py` with just
`SHOW_GRAVATAR_IMAGE = False` in it and placed it next do my
`docker-compose.yml`. In the `volumes` section of `docker-compose.yml` I
added `- ./config_local.py:/pgadmin4/config_local.py` and restarted the
container. Voila the Gravatar icon is gone. Thank you for the advice,
that worked.

Sidenote: IMHO it would be a sane default to NOT have Gravatar
integration turned on.

mcnesium

Am 2018-11-19 13:01, schrieb Dave Page:
> On Mon, Nov 19, 2018 at 11:39 AM <mail(at)mcnesium(dot)com> wrote:
>
>> After upgrading form 3.1 to 3.5 the environment variable
>> SHOW_GRAVATAR_IMAGE is not being processed anymore, or rather: it
>> still
>> loads data from an unsolicited third party and tells them the mail
>> address of the pgadmin user.
>>
>> docker-compose.yml:
>>
>> …
>> environment:
>> - SHOW_GRAVATAR_IMAGE=False
>> …
>>
>> docker exec -ti pgadmin sh
>>
>> /pgadmin4 # echo $SHOW_GRAVATAR_IMAGE
>> False
>> /pgadmin4 # grep -i gravatar ./config.py
>> # Allow users to display Gravatar image for their username in Server
>>
>> mode
>> SHOW_GRAVATAR_IMAGE = True
>>
>> What can I do about that?
>
> SHOW_GRAVATAR_IMAGE has never been read from the environment in the
> pgAdmin code or the official Docker container.
>
> You could probably override it by creating a config_local.py file on
> the host, and launching with it mounted in the right place in the
> container - e.g.
>
> docker run -p 443:443 -v
> "/path/to/config_local.py:/pgadmin4/config_local.py" ...
>
> I haven't tested that, but it should work in theory. I don't know how
> you'd translate that into Compose.
>
> --
> Dave Page
> Blog: http://pgsnake.blogspot.com
> Twitter: @pgsnake
>
> EnterpriseDB UK: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company

In response to

Browse pgadmin-support by date

  From Date Subject
Next Message Vladislav Ivanov 2018-11-19 13:44:30 Does Not start
Previous Message Dave Page 2018-11-19 12:01:47 Re: SHOW_GRAVATAR_IMAGE ignored