fix: mount Keycloak PostgreSQL data at official postgres path - #296
Open
linuxfreakus wants to merge 1 commit into
Open
fix: mount Keycloak PostgreSQL data at official postgres path#296linuxfreakus wants to merge 1 commit into
linuxfreakus wants to merge 1 commit into
Conversation
The volume was mounted at /var/lib/pgsql/data (RHEL/SCL) while PGDATA and library/postgres use /var/lib/postgresql/data/pgdata, so the PVC was never used and Keycloak DB data was not persisted. Align mountPath with the Helm chart and PGDATA. Fixes microcks#295 Signed-off-by: Eric Nichols <linuxfreakus@gmail.com>
|
Welcome to the Microcks community! 💖 Thanks and congrats 🎉 for opening your first pull request here! Be sure to follow the pull request template or please update it accordingly. Hope you have a great time there! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes a data-loss bug where the Keycloak PostgreSQL volume was mounted at the wrong path and never used by the official
library/postgresimage.library/postgresPGDATA/var/lib/postgresql/data/pgdatavolumeMounts.mountPath/var/lib/pgsql/data(RHEL/SCL)/var/lib/postgresql/dataWith the old mount path, Postgres wrote under
PGDATAon the container filesystem. The PVC/emptyDir at/var/lib/pgsql/datastayed empty, sokeycloak.persistent: truedid not persist Keycloak DB data across pod restarts.This matches the already-correct Helm chart layout in
microcks/microcks(mountPath: /var/lib/postgresql/data+subPath: pgdata+ samePGDATA).Related
PGDATA+subPathfor OpenShift permissions but left the RHELmountPathin placeTest plan
MicrocksCR withkeycloak.install: trueandkeycloak.persistent: truekubectl exec … -- df -h /var/lib/postgresql/data(or inspect Deployment volumeMounts)