Skip to content

PostgreSQL 18#2489

Merged
yorickdowne merged 1 commit intoethstaker:mainfrom
yorickdowne:postgres-18
Mar 16, 2026
Merged

PostgreSQL 18#2489
yorickdowne merged 1 commit intoethstaker:mainfrom
yorickdowne:postgres-18

Conversation

@yorickdowne
Copy link
Copy Markdown
Collaborator

@yorickdowne yorickdowne commented Mar 12, 2026

What I did

PostgreSQL 18.3 was released February 26th, and I consider 18 to be stable now.

This will prompt users to migrate to 18.

PostgreSQL has changed where it expects data. The cleanest way I found to handle this is to set PGDATA manually
and mount the volume outside of /var/lib/postgresql, to avoid issues that arise from conflicts between old and new.
Old: Mount to /var/lib/postgresql/data
New: Mount to /var/lib/postgresql, data is a symlink, DB is in <MAJOR_VERSION>/docker

I set PGDATA=/var/lib/postgres-data and mount the volume to there. That allows existing users to work and have slashing protection, it allows new setups, and it allows migration.

Also strengthened error handling.

Pucker factor is high: A fatal bug here gets people slashed.

This is the third migration since the code was introduced. First was 15->16, second 16->17, now 17->18.

@yorickdowne yorickdowne marked this pull request as draft March 12, 2026 19:05
@yorickdowne yorickdowne requested a review from pietjepuk2 March 14, 2026 12:31
@yorickdowne yorickdowne marked this pull request as ready for review March 14, 2026 12:31
@yorickdowne yorickdowne force-pushed the postgres-18 branch 6 times, most recently from 6f86b67 to aa66508 Compare March 16, 2026 09:09
@yorickdowne yorickdowne merged commit 3224d74 into ethstaker:main Mar 16, 2026
192 checks passed
@yorickdowne yorickdowne deleted the postgres-18 branch March 16, 2026 10:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants