Starefossen / docker-pgrouting

:whale: Docker Image for pgRouting with PostGIS and official Postgres Docker Image
https://registry.hub.docker.com/u/starefossen/pgrouting/
MIT License
33 stars 19 forks source link

Container initialization fails when POSTGRES_USER != postgres #21

Open azapasnik opened 5 years ago

azapasnik commented 5 years ago

Container initialization fails with error in case when environment variable POSTGRES_USER is set to something that doesn't equals to postgres.

Initialization error:

...
/usr/local/bin/docker-entrypoint.sh: running /docker-entrypoint-initdb.d/routing.sh
2019-04-23 13:27:42.903 UTC [96] FATAL:  role "postgres" does not exist

To reproduce: docker run -e POSTGRES_USER=test -e POSTGRES_DB=test -e POSTGRES_PASSWORD=test starefossen/pgrouting