-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Closed
Labels
questionUsability question, not directly related to an error with the imageUsability question, not directly related to an error with the image
Description
As described in this issue comment the execution of the following command returns an exception if no database called admin exists.
bash-5.0# export PGPASSWORD=$DB_PASS
bash-5.0# psql -h $DB_HOST -U $DB_USER -c 'COPY (SELECT datname FROM pg_database WHERE datistemplate = false) TO STDOUT;'
psql: error: FATAL: database "admin" does not exist
Using the following docker-compose file will create me a new postgres container with missing admin database. I think an admin db should be added automatically to make the above command work.
postgres:
image: postgres:12.1-alpine
hostname: postgres
container_name: postgres
restart: always
environment:
POSTGRES_USER: ${POSTGRESUSER}
POSTGRES_PASSWORD: ${POSTGRESPW}
POSTGRES_DB: ${POSTGRESDB}
volumes:
- postgres-data:/var/lib/postgresql/data
Metadata
Metadata
Assignees
Labels
questionUsability question, not directly related to an error with the imageUsability question, not directly related to an error with the image