From 84ca400dcfcd5b964800c6f7a58e5d618eddde4f Mon Sep 17 00:00:00 2001 From: Alexey Masterov Date: Tue, 10 Sep 2024 11:10:11 +0200 Subject: [PATCH] We are going to calculate md5 sum dynamically --- .github/workflows/cloud-regress.yml | 7 +++++++ patches/cloud_regress_pg16.patch | 10 +++++----- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/workflows/cloud-regress.yml b/.github/workflows/cloud-regress.yml index b5f978342b44..65926c78e9bf 100644 --- a/.github/workflows/cloud-regress.yml +++ b/.github/workflows/cloud-regress.yml @@ -65,6 +65,13 @@ jobs: for fname in sql/*.sql expected/*.out; do sed -i.bak s/NEON_PASSWORD_PLACEHOLDER/"'${{ steps.pwgen.outputs.DBPASS }}'"/ "${fname}" done + for ph in $(grep NEON_MD5_PLACEHOLDER expected/password.out | awk '{print $3;}' | sort | uniq); do + USER=$(echo ${ph} | cut -c 22-) + MD5=md5$(echo -n "${{ steps.pwgen.outputs.DBPASS }}${USER}" | md5sum | awk '{print $1;}') + sed -i.bak "s/${ph}/$MD5/" expected/password.out + done + + - name: Download Neon artifact uses: ./.github/actions/download diff --git a/patches/cloud_regress_pg16.patch b/patches/cloud_regress_pg16.patch index f227a533978b..d15d0cffebc3 100644 --- a/patches/cloud_regress_pg16.patch +++ b/patches/cloud_regress_pg16.patch @@ -981,7 +981,7 @@ index fc42d418bf..e38f517574 100644 CREATE SCHEMA addr_nsp; SET search_path TO 'addr_nsp'; diff --git a/src/test/regress/expected/password.out b/src/test/regress/expected/password.out -index 8475231735..e135d095f4 100644 +index 8475231735..1afae5395f 100644 --- a/src/test/regress/expected/password.out +++ b/src/test/regress/expected/password.out @@ -12,11 +12,11 @@ SET password_encryption = 'md5'; -- ok @@ -1006,8 +1006,8 @@ index 8475231735..e135d095f4 100644 -----------------+--------------------------------------------------- - regress_passwd1 | md5783277baca28003b33453252be4dbb34 - regress_passwd2 | md54044304ba511dd062133eb5b4b84a2a3 -+ regress_passwd1 | md5cf164b1eb55cd11cd73be38189a421f6 -+ regress_passwd2 | md51b973138181bae7549ef288d52425a2e ++ regress_passwd1 | NEON_MD5_PLACEHOLDER_regress_passwd1 ++ regress_passwd2 | NEON_MD5_PLACEHOLDER_regress_passwd2 regress_passwd3 | SCRAM-SHA-256$4096:$: - regress_passwd4 | + regress_passwd4 | SCRAM-SHA-256$4096:$: @@ -1053,8 +1053,8 @@ index 8475231735..e135d095f4 100644 -----------------+--------------------------------------------------- - regress_passwd1 | md5cd3578025fe2c3d7ed1b9a9b26238b70 - regress_passwd2 | md5dfa155cadd5f4ad57860162f3fab9cdb -+ regress_passwd1 | md5cf164b1eb55cd11cd73be38189a421f6 -+ regress_passwd2 | md51c72b7907ee13c2116fd36cc255ed306 ++ regress_passwd1 | NEON_MD5_PLACEHOLDER_regress_passwd1 ++ regress_passwd2 | NEON_MD5_PLACEHOLDER_regress_passwd2 regress_passwd3 | SCRAM-SHA-256$4096:$: regress_passwd4 | SCRAM-SHA-256$4096:$: - regress_passwd5 | md5e73a4b11df52a6068f8b39f90be36023