Skip to content

Commit 3cbe23c

Browse files
authored
chore: wip upgrade pgroonga to latest (#1418)
* chore: wip upgrade pgroonga to latest * chore: strings for staging tests of image * chore: staging version * chore: bump staging vrsion * chore: GRN_PLUGINS_DIR env var * chore: make sure nix available * chore: no longer need sudo * chore: bump version * chore: bump upload artifact action
1 parent d39d274 commit 3cbe23c

File tree

8 files changed

+63
-11
lines changed

8 files changed

+63
-11
lines changed

.github/workflows/dockerhub-release-matrix.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ jobs:
157157
run: |
158158
echo "${{ steps.output_version.outputs.result }}" >> results.txt # Append results
159159
- name: Upload Results Artifact
160-
uses: actions/upload-artifact@v3
160+
uses: actions/upload-artifact@v4
161161
with:
162162
name: merge_results-${{ matrix.version }}
163163
path: results.txt

.github/workflows/publish-nix-pgupgrade-bin-flake-version.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,13 @@ jobs:
3737
steps:
3838
- name: Checkout Repo
3939
uses: actions/checkout@v3
40+
41+
- uses: DeterminateSystems/nix-installer-action@main
4042

4143
- name: Grab release version
4244
id: process_release_version
4345
run: |
44-
VERSION=$(sudo nix run nixpkgs#yq -- '.postgres_release["postgres'${{ matrix.postgres_version }}'"]' ansible/vars.yml)
46+
VERSION=$(nix run nixpkgs#yq -- '.postgres_release["postgres'${{ matrix.postgres_version }}'"]' ansible/vars.yml)
4547
VERSION=$(echo $VERSION | tr -d '"') # Remove any surrounding quotes
4648
if [[ "${{ inputs.postgresVersion }}" != "" ]]; then
4749
VERSION=${{ inputs.postgresVersion }}

ansible/files/admin_api_scripts/pg_upgrade_scripts/initiate.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ EOF
419419
if [ "$IS_NIX_BASED_SYSTEM" = "true" ]; then
420420
UPGRADE_COMMAND=". /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh && $UPGRADE_COMMAND"
421421
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
423423

424424
echo "10. Stopping postgres; running pg_upgrade"
425425
# Extra work to ensure postgres is actually stopped
@@ -435,7 +435,7 @@ EOF
435435
CI_stop_postgres
436436
fi
437437

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
439439

440440
# copying custom configurations
441441
echo "11. Copying custom configurations"

ansible/vars.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ postgres_major:
88

99
# Full version strings for each major version
1010
postgres_release:
11-
postgresorioledb-17: "17.0.1.030-orioledb"
12-
postgres15: "15.8.1.034"
11+
postgresorioledb-17: "17.0.1.31-orioledb"
12+
postgres15: "15.8.1.035"
1313

1414
# Non Postgres Extensions
1515
pgbouncer_release: "1.19.0"

nix/ext/pgroonga.nix

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ let
44
in
55
stdenv.mkDerivation rec {
66
pname = "pgroonga";
7-
version = "3.0.7";
7+
version = "3.2.5";
88
src = fetchurl {
99
url = "https://packages.groonga.org/source/${pname}/${pname}-${version}.tar.gz";
10-
sha256 = "sha256-iF/zh4zDDpAw5fxW1WG8i2bfPt4VYsnYArwOoE/lwgM=";
10+
sha256 = "sha256-GM9EOQty72hdE4Ecq8jpDudhZLiH3pP9ODLxs8DXcSY=";
1111
};
1212
nativeBuildInputs = [ pkg-config makeWrapper ];
1313

nix/tests/expected/z_15_ext_interface.out

+22-1
Large diffs are not rendered by default.

nix/tests/expected/z_17_ext_interface.out

+22-1
Large diffs are not rendered by default.

nix/tools/run-client.sh.in

+9-1
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,15 @@ while [[ "$#" -gt 0 ]]; do
6464
exit 1
6565
fi
6666
;;
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+
;;
6776
-h|--help)
6877
print_help
6978
exit 0
@@ -106,7 +115,6 @@ export PATH=$BINDIR/bin:$PATH
106115
export POSTGRES_DB=postgres
107116
export POSTGRES_HOST=localhost
108117

109-
PORTNO="${2:-@PGSQL_DEFAULT_PORT@}"
110118
PGSQL_SUPERUSER=@PGSQL_SUPERUSER@
111119
MIGRATIONS_DIR=@MIGRATIONS_DIR@
112120
POSTGRESQL_SCHEMA_SQL=@POSTGRESQL_SCHEMA_SQL@

0 commit comments

Comments
 (0)