Skip to content
Snippets Groups Projects
Commit fb2c628f authored by Eliot Berriot's avatar Eliot Berriot
Browse files

Update paths to reflect our recommended setups

parent 5ab0dd71
No related merge requests found
Pipeline #3100 passed with stages
in 4 minutes and 51 seconds
......@@ -83,15 +83,16 @@ keeping a backup of the old version in ``./postgres-old``:
# Replace "9.4" and "11" with the versions you are migrating between.
export OLD_POSTGRES=9.4
export NEW_POSTGRES=11
docker-compose stop postgres
docker run --rm \
-v `pwd`/postgres:/var/lib/postgresql/${OLD_POSTGRES}/data \
-v `pwd`/postgres-new:/var/lib/postgresql/${NEW_POSTGRES}/data \
-v `pwd`/data/postgres:/var/lib/postgresql/${OLD_POSTGRES}/data \
-v `pwd`/data/postgres-new:/var/lib/postgresql/${NEW_POSTGRES}/data \
tianon/postgres-upgrade:${OLD_POSTGRES}-to-${NEW_POSTGRES}
# Add back the access control rule that doesn't survive the upgrade
echo "host all all all trust" | sudo tee -a ./postgres-new/pg_hba.conf
# Swap over to the new database
mv ./postgres ./postgres-old
mv ./postgres-new ./postgres
mv ./data/postgres ./data/postgres-old
mv ./data/postgres-new ./data/postgres
Non-docker setup
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment