Skip to content

PostgreSQL 16 needed for GitLab 18 #3096

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

Open
mihelm opened this issue Apr 18, 2025 · 7 comments
Open

PostgreSQL 16 needed for GitLab 18 #3096

mihelm opened this issue Apr 18, 2025 · 7 comments

Comments

@mihelm
Copy link

mihelm commented Apr 18, 2025

The blog post on the release of GitLab 17.11 contains this bit:

In GitLab 18.0, the minimum-supported version of PostgreSQL will be version 16. To prepare for this change, on instances that don’t use PostgreSQL Cluster, upgrades to GitLab 17.11 will attempt to automatically upgrade PostgreSQL to version 16.

What are the prospects for a sameersbn/postgresql image with version 16?

@pmoralesp
Copy link
Contributor

Just updated to 17.11.0 and broke my setup because of this

@th-2021
Copy link
Contributor

th-2021 commented Apr 25, 2025

The upcoming release page mentions: 18.0 (2025-05-15)

@kkimurak
Copy link
Contributor

I think this should probably be discussed in the sameersbn/docker-postgresql repository, not here (I don't know if there will be a response from the maintainers early on, i.e. before the release of gitlab 18 when postgresql16 becomes mandatory..)

Anyway, as a temporary workaround, I pushed kkimurak/sameersbn-postgresql I built myself. Currently :15 (:15.12, :15.12-1) and :16 (:16.8, :16.8-1) are available. I have confirmed that the scheduled backup using :16.8-1 works properly in combination with sameersbn/gitlab:17.11.0.
See https://hub.docker.com/r/kkimurak/sameersbn-postgresql/tags

@mihelm
Copy link
Author

mihelm commented Apr 26, 2025

@kkimurak Thanks a lot for posting that! With that I was able to upgrade, and the database migration went without a hitch.

@kkimurak
Copy link
Contributor

@mihelm Glad it works.


For now, I plan to continue regular updates until the upstream repository is updated, I get tired of it, or I find a new place to migrate to. I might try linking it to an automatic dependency update service such as renovate, or setting up a github action to push periodically, while also learning about it. Of course, there are no guarantees.
Also, I haven't pushed to quay.io yet. I haven't signed up for the lowest development plan yet because it costs $15/month. I haven't decided whether to sign up or not.

@th-2021
Copy link
Contributor

th-2021 commented May 3, 2025

@kkimurak which tags should be used for your psql? I have 16.8-1-20250424, which works well, but I saw that you also pushed 16.8-1 without date.

@kkimurak
Copy link
Contributor

kkimurak commented May 3, 2025

@th-2021 Maybe :16 is suitable for most case. If you need fixed version tag you can specify {MAJOR-YYYYMMDD} (like 16-20250501) or image hash. I'm setting up to build all supported versions (currently 13.x to 17.x) every week so you can update by stop, rm, rmi and then pull new image.
I'm still thinking about what tag names format to use so the naming is differ (16-20250501) from last week (16.8-1-20250424)

Note that I'm using a script to build these images. This script will:

  1. list up major versions of postgresql to support
  2. update Dockerfile to set PG_VERSION to target major version and run docker build for each major versions
  3. check output of psql --version
  4. set tags ({MAJOR}, {MAJOR-YYYYMMDD}, {MAJOR.MINOR} and {MAJOR.MINOR-PATCH})

Finally I run docker push --all-tags. So, the latest version of postgresql that corresponds to the image tag name should be included. (That is, for example, if 16.9 is released in the future, tag:16 will include postgresql 16.9(-1), but tag:16.8 will remain as it was when 16.8 was installed at the time of build and will not be updated.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants