Upgrade your PostgreSQL from one version to another.
Find a file
CI 368358ef64 Update actions/checkout action to v6 (#4)
Reviewed-on: #4
Co-authored-by: CI <ci@16reiche.de>
Co-committed-by: CI <ci@16reiche.de>
2025-11-21 08:57:16 +01:00
.forgejo/workflows Update actions/checkout action to v6 (#4) 2025-11-21 08:57:16 +01:00
14-to-15 Fix 14 to 15 2024-04-30 16:45:05 +02:00
15-to-16 Fix CHMOD 2024-04-29 12:10:18 +02:00
16-to-17 Workflow für 16 zu 17 2025-01-04 09:40:52 +01:00
docker-upgrade Also chown "." (used for log files, etc) 2016-05-24 17:23:34 -07:00
README.md Adjust README and branch details 2024-04-29 12:37:55 +02:00
renovate.json Configure Renovate (#1) 2024-05-01 10:21:20 +02:00

PostgreSQL Upgrade

This is a fork of https://github.com/tianon/docker-postgres-upgrade.

Update process

  • Create a new directory for the new PostgreSQL version
  • Pull the docker image docker pull source.16reiche.de/thirdparty/docker-postgres-upgrade:15-to-16
    • Exchange the versions according to the update you want to perfrom.
  • Scale down the running PostgreSQL service to 0
  • Run
	docker run --rm \
	-v /home/storage/postgres_data_15:/var/lib/postgresql/15/data \
	-v /home/storage/postgres_data_16:/var/lib/postgresql/16/data \
	source.16reiche.de/thirdparty/docker-postgres-upgrade:15-to-16
  • Exchange the version numbers accordingly
  • Make sure the paths on the left side of the volume definition match your host paths.
  • Adjust your deployment
    • Point to the new DB directory.
    • Use the new PostgreSQL version
  • Remove the volume
  • Open pg_hba.conf and change the IPv4 definition to 0.0.0.0/0
  • Deploy the service