-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to access postgres-postgis with .env file values #2922
Comments
try upgrade docker-compose |
I am having this exact issue in ▶ docker-compose up postgres-postgis
Starting laradock_postgres-postgis_1 ... done
Attaching to laradock_postgres-postgis_1
postgres-postgis_1 | 2021-06-03 01:17:40.596 UTC [1] FATAL: database files are incompatible with server
postgres-postgis_1 | 2021-06-03 01:17:40.596 UTC [1] DETAIL: The data directory was initialized by PostgreSQL version 13, which is not compatible with this version 11.2 (Debian 11.2-1.pgdg90+1).
laradock_postgres-postgis_1 exited with code 1
This seems to be what is causing the issue. While postgres container is using version 13.
|
@alexc-tti Did you resolve this issue?
Solution is change FROM to postgis/postgis:latest
But changing this file is not enough you have to fully upgrade laradock to latest version Now in your .env file in laravel project.
@bestlong You can probably close this issue now. |
Description:
Running
docker-compose up -d postgres-postgis
does not create a database with the variables set in the .env file (DB: default, user: default, password: secret). Attempting to access the DB using any role (root, postgres, etc) fails saying the role does not exist.Manually specifying the role and changing the data path does work, e.g.
Connecting to 127.0.0.1 using postgres/postgres shows the databases correctly and allows psql to work through bash.
Expected Behavior:
Creation of role "default" with password "secret" for access to database "default", as specified in .env.
Context information:
Output of
git rev-parse HEAD
Output of
docker version
Output of
docker-compose version
System info: Mac, Windows or Linux. Include which disto/version
Steps to reproduce the issue:
docker-compose up -d postgres-postgis
with .env vars set to defaultsThe text was updated successfully, but these errors were encountered: