File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
ansible/files/admin_api_scripts/pg_upgrade_scripts Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -43,8 +43,8 @@ POST_UPGRADE_EXTENSION_SCRIPT="/tmp/pg_upgrade/pg_upgrade_extensions.sql"
43
43
POST_UPGRADE_POSTGRES_PERMS_SCRIPT=" /tmp/pg_upgrade/pg_upgrade_postgres_perms.sql"
44
44
OLD_PGVERSION=$( pg_config --version | sed ' s/PostgreSQL \([0-9]*\.[0-9]*\).*/\1/' )
45
45
46
- # Skip locale settings if both versions are PostgreSQL 17+ or 17-orioledb
47
- if ! [[ (( "$OLD_PGVERSION " =~ ^17 .* || " $OLD_PGVERSION " == " 17 - orioledb") && ( "$PGVERSION " =~ ^17 .* || " $PGVERSION " == " 17 - orioledb" )) ]]; then
46
+ # Skip locale settings if both versions are PostgreSQL 17+
47
+ if ! [[ " $OLD_PGVERSION " =~ ^17.* && " $PGVERSION " =~ ^17.* ]]; then
48
48
SERVER_LC_COLLATE=$( run_sql -A -t -c " SHOW lc_collate;" )
49
49
SERVER_LC_CTYPE=$( run_sql -A -t -c " SHOW lc_ctype;" )
50
50
fi
@@ -436,7 +436,7 @@ $(cat /etc/postgresql/pg_hba.conf)" > /etc/postgresql/pg_hba.conf
436
436
fi
437
437
438
438
# Remove db_user_namespace if upgrading from PG15
439
- if [[ " $OLD_PGVERSION " =~ ^15.* ]]; then
439
+ if [[ " $OLD_PGVERSION " =~ ^15.* && " $PGVERSION " =~ ^17. * ]]; then
440
440
sed -i ' /^db_user_namespace/d' " $TMP_CONFIG "
441
441
fi
442
442
You can’t perform that action at this time.
0 commit comments