-
Notifications
You must be signed in to change notification settings - Fork 470
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
POstgres 15 image does not work with Gitlab backup:restore task - "permission denied for schema public" #168
Comments
Postgres 15 has a permissions problem. See sameersbn/docker-postgresql#168
Postgres 15 has a permissions problem. See sameersbn/docker-postgresql#168
Postgres 15 has a permissions problem. See sameersbn/docker-postgresql#168
Postgres 15 has a permissions problem. See sameersbn/docker-postgresql#168
I might have the same issue. In my case I created a new database for SonarQube: containers:
- name: postgres
image: docker.io/sameersbn/postgresql:15@sha256:f5f9f8ad3b873d49a44e21c3f17231da3f92db7f0f73119215b7c771faf53e13
env:
- name: DB_NAME
value: sonar
- name: DB_PASS
value: sonar
- name: DB_USER
value: sonar I got As a workaround I used an initContainer (on the SonarQube pod, after the PostgreSQL database is already up and running): - name: create-schema
image: docker.io/sameersbn/postgresql:15@sha256:f5f9f8ad3b873d49a44e21c3f17231da3f92db7f0f73119215b7c771faf53e13
env:
- name: PGPASSWORD
value: sonar
command:
- psql
args:
- --dbname=sonar
- --command=CREATE SCHEMA IF NOT EXISTS AUTHORIZATION sonar;
- --host=postgres
- --no-password
- --username=sonar I am wondering if something like Version: PS. I still have to double-check if my workaround actually works. |
Due to this change in user permission in postgres 15:
https://stackoverflow.com/questions/74110708/postgres-15-permission-denied-for-schema-public/74111630#comment130849690_74110708
I tried running the db:setup rake task prior to running the backup script.
During backup restore, all SQL statements fail due to permission error.
I am upgrading from 15.11.5 to 16.0.0. Postgres 12 to 15 (using the sameersbn/postgres images).
The text was updated successfully, but these errors were encountered: