Skip to content

Avoid automatic minor version upgrades of PostgreSQL during image builds #186

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

Closed
fcanovai opened this issue May 12, 2025 · 0 comments · Fixed by #187
Closed

Avoid automatic minor version upgrades of PostgreSQL during image builds #186

fcanovai opened this issue May 12, 2025 · 0 comments · Fixed by #187
Assignees
Labels
bug Something isn't working

Comments

@fcanovai
Copy link
Contributor

In #93 there was a misalignment between the declared minor and the actual pg version installed in the container. This was caused by the container release happening after the pgdg package release, with our rebuild happening in between.

PostgreSQL 16.2 was out on 2024-02-08. The postgresql community image was out on 2024-02-12. pgvector 0.6.0 was packaged on 2024-02-09, with the following dependencies on bullseye:

Depends: postgresql-16, postgresql-16-jit-llvm (>= 13), libc6 (>= 2.14)

However, that dependency wasn't satisfied by postgresql-16.1

Version: 16.1-1.pgdg110+1
Provides: postgresql-16-jit-llvm (= 11), postgresql-contrib-16

And 16.2 was already available, so it upgraded.

This can happen on every minor upgrade. We should prevent unwanted minor upgrades.

@fcanovai fcanovai self-assigned this May 12, 2025
fcanovai added a commit to fcanovai/postgres-containers that referenced this issue May 12, 2025
When building a system image, we start from a community postgres image.
There is the chance that newer postgres packages are released, and they
could be upgraded when installing the supported extensions. We want to
prevent this scenario, as it could lead to unexpected versions in the
container image.

Closes cloudnative-pg#186

Signed-off-by: Francesco Canovai <[email protected]>
fcanovai added a commit to fcanovai/postgres-containers that referenced this issue May 12, 2025
When building a system image, we start from a community postgres image.
There is the chance that newer postgres packages are released, and they
could be upgraded when installing the supported extensions. We want to
prevent this scenario, as it could lead to unexpected versions in the
container image.

Closes cloudnative-pg#186

Signed-off-by: Francesco Canovai <[email protected]>
@dosubot dosubot bot added the bug Something isn't working label May 12, 2025
mnencia pushed a commit that referenced this issue May 12, 2025
When building a system image, we start from a community postgres image.
There is the chance that newer postgres packages are released, and they
could be upgraded when installing the supported extensions. We want to
prevent this scenario, as it could lead to unexpected versions in the
container image.

Closes #186

Signed-off-by: Francesco Canovai <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant