File tree Expand file tree Collapse file tree 2 files changed +11
-3
lines changed
ansible/files/admin_api_scripts/pg_upgrade_scripts Expand file tree Collapse file tree 2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change 419
419
if [ " $IS_NIX_BASED_SYSTEM " = " true" ]; then
420
420
UPGRADE_COMMAND=" . /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh && $UPGRADE_COMMAND "
421
421
fi
422
- LC_ALL=en_US.UTF-8 LC_CTYPE=$SERVER_LC_CTYPE LC_COLLATE=$SERVER_LC_COLLATE LANGUAGE=en_US.UTF-8 LANG=en_US.UTF-8 LOCALE_ARCHIVE=/usr/lib/locale/locale-archive su -pc " $UPGRADE_COMMAND --check" -s " $SHELL " postgres
422
+ GRN_PLUGINS_DIR=/var/lib/postgresql/.nix-profile/lib/groonga/plugins LC_ALL=en_US.UTF-8 LC_CTYPE=$SERVER_LC_CTYPE LC_COLLATE=$SERVER_LC_COLLATE LANGUAGE=en_US.UTF-8 LANG=en_US.UTF-8 LOCALE_ARCHIVE=/usr/lib/locale/locale-archive su -pc " $UPGRADE_COMMAND --check" -s " $SHELL " postgres
423
423
424
424
echo " 10. Stopping postgres; running pg_upgrade"
425
425
# Extra work to ensure postgres is actually stopped
435
435
CI_stop_postgres
436
436
fi
437
437
438
- LC_ALL=en_US.UTF-8 LC_CTYPE=$SERVER_LC_CTYPE LC_COLLATE=$SERVER_LC_COLLATE LANGUAGE=en_US.UTF-8 LANG=en_US.UTF-8 LOCALE_ARCHIVE=/usr/lib/locale/locale-archive su -pc " $UPGRADE_COMMAND " -s " $SHELL " postgres
438
+ GRN_PLUGINS_DIR=/var/lib/postgresql/.nix-profile/lib/groonga/plugins LC_ALL=en_US.UTF-8 LC_CTYPE=$SERVER_LC_CTYPE LC_COLLATE=$SERVER_LC_COLLATE LANGUAGE=en_US.UTF-8 LANG=en_US.UTF-8 LOCALE_ARCHIVE=/usr/lib/locale/locale-archive su -pc " $UPGRADE_COMMAND " -s " $SHELL " postgres
439
439
440
440
# copying custom configurations
441
441
echo " 11. Copying custom configurations"
Original file line number Diff line number Diff line change @@ -64,6 +64,15 @@ while [[ "$#" -gt 0 ]]; do
64
64
exit 1
65
65
fi
66
66
;;
67
+ -p|--port)
68
+ if [[ -n " $2 " && ! " $2 " =~ ^- ]]; then
69
+ PORTNO=" $2 "
70
+ shift 2
71
+ else
72
+ echo " Error: --port requires an argument"
73
+ exit 1
74
+ fi
75
+ ;;
67
76
-h|--help)
68
77
print_help
69
78
exit 0
@@ -106,7 +115,6 @@ export PATH=$BINDIR/bin:$PATH
106
115
export POSTGRES_DB=postgres
107
116
export POSTGRES_HOST=localhost
108
117
109
- PORTNO=" ${2:-@ PGSQL_DEFAULT_PORT@ } "
110
118
PGSQL_SUPERUSER=@PGSQL_SUPERUSER@
111
119
MIGRATIONS_DIR=@MIGRATIONS_DIR@
112
120
POSTGRESQL_SCHEMA_SQL=@POSTGRESQL_SCHEMA_SQL@
You can’t perform that action at this time.
0 commit comments