Problem related to volume creation to pgadmin 4 Docker image

Поиск
Список
Период
Сортировка
От Rodrigo Mariano
Тема Problem related to volume creation to pgadmin 4 Docker image
Дата
Msg-id aa45a013-826c-745d-6537-649cdaddc304@gmail.com
обсуждение исходный текст
Ответы Re: Problem related to volume creation to pgadmin 4 Docker image  (Aditya Toshniwal <aditya.toshniwal@enterprisedb.com>)
Список pgadmin-support

Hi,

I'm having a trouble related to pgadmin 4 Docker image <https://hub.docker.com/r/dpage/pgadmin4>.

I would like to create a volume to /var/lib/pgadmin/storage folder, in order to access backup files created by pgadmin 4 interface, however error messages about permission denied are raised, for example:

werkzeug.exceptions.InternalServerError: 500 Internal Server Error: The user does not have permission to read and write to the specified storage directory.

Is there a way to create this volume?

I had to use a command to change user and group of my volume to 5050:5050 (i.e. sudo chown -R 5050:5050 pgadmin4), but now I'm not able to get into the folder anymore, even when I try creating a volume to /var/lib/pgadmin/storage folder directly.

I send below my Docker compose file with default values.

Thank you in advance.

Best regards,
Rodrigo

-

docker-compose.yml

version: '3'

services:
  cdsr_postgis:
    container_name: cdsr_postgis
    image: kartoza/postgis:11.0-2.5
    restart: on-failure
    environment:
      - POSTGRES_USER=postgres
      - POSTGRES_PASS=postgres
      - ALLOW_IP_RANGE=0.0.0.0/0
      - POSTGRES_MULTIPLE_EXTENSIONS=postgis,hstore,postgis_topology,pgrouting
    volumes:
      - ./volumes/postgresql:/var/lib/postgresql
    networks:
      - cdsr
    ports:
      - 6000:5432

  cdsr_pgadmin4:
    container_name: cdsr_pgadmin4
    image: dpage/pgadmin4:5.4
    restart: on-failure
    environment:
      - PGADMIN_DEFAULT_EMAIL=postgres@localhost.com
      - PGADMIN_DEFAULT_PASSWORD=postgres
    volumes:
      # to fix permission bugs:
      # sudo chown -R 5050:5050 pgadmin4
      - ./volumes/pgadmin4:/var/lib/pgadmin
      - ./volumes/pgadmin4_storage:/var/lib/pgadmin/storage
    networks:
      - cdsr
    depends_on:
      - cdsr_postgis
    ports:
      - 6001:80

networks:
  cdsr:
    driver: bridge

В списке pgadmin-support по дате отправления:

Предыдущее
От: Aditya Toshniwal
Дата:
Сообщение: Re: PG ADMIN V 6 ERD Diagram
Следующее
От: Aditya Toshniwal
Дата:
Сообщение: Re: Problem related to volume creation to pgadmin 4 Docker image