Skip to content

Commit 4ea0bfa

Browse files
authored
Segregate postgres upgrade instructions on version
The previous instructions always instructed the reader to undo the base image and postgres template in the container configuration. If the upgrade were done from 9.3, that might be confusing as the `base_image` property had never been altered in a previous step.
1 parent 2ec550f commit 4ea0bfa

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

templates/postgres.template.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,12 @@ run:
9292
echo Run "./launcher enter app"
9393
echo Run "cd /shared/postgres_backup && sudo -u postgres pg_dump discourse > backup.db"
9494
echo
95-
echo Undo the base_image and postgres template from your container config
95+
if [ "$PG_MAJOR_OLD" = "9.2" ]; then
96+
echo Undo the base_image in your container config
97+
fi
98+
if [ "$PG_MAJOR_OLD" = "9.3" ]; then
99+
echo Undo the postgres template in your container config
100+
fi
96101
echo Run: "./launcher stop app"
97102
echo Run: "sudo mv /var/discourse/shared/standalone/postgres_data /var/discourse/shared/standalone/postgres_data_old"
98103
echo Run: "./launcher rebuild app"

0 commit comments

Comments
 (0)