diff --git a/pmm_qa/mlaunch_setup.sh b/pmm_qa/mlaunch_setup.sh index d5d4d9c..a3ee14a 100755 --- a/pmm_qa/mlaunch_setup.sh +++ b/pmm_qa/mlaunch_setup.sh @@ -36,10 +36,10 @@ sleep 10 export SERVICE_RANDOM_NUMBER=$(echo $((1 + $RANDOM % 9999))) ### Detect latest tarball link for specified mongodb_version: 7.0 | 6.0 | 5.0 | 4.4 | 4.2 at the moment -psmdb_latest=$(wget -q --post-data "version=percona-server-mongodb-${mongodb_version}" https://www.percona.com/products-api.php -O - | grep -oP "(?<=value\=\")[^\"]*" | sort -V | tail -1) -psmdb_tarball=$(wget -q --post-data "version_files=${psmdb_latest}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep glibc2\.17-minimal) +# psmdb_latest=$(wget -q --post-data "version=percona-server-mongodb-${mongodb_version}" https://www.percona.com/products-api.php -O - | grep -oP "(?<=value\=\")[^\"]*" | sort -V | tail -1) +psmdb_tarball=$(wget -q --post-data "version_files=percona-server-mongodb-${mongodb_version}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep glibc2\.17-minimal) -echo "Downloading ${psmdb_latest} ..." +echo "Downloading ${mongodb_version} ..." wget -O percona_server_mongodb.tar.gz ${psmdb_tarball} tar -xvf percona_server_mongodb.tar.gz @@ -51,7 +51,7 @@ mv ${extracted_folder_name} psmdb_${mongodb_version} if [[ "$mongodb_version" == "6.0" || "$mongodb_version" == "7.0" ]]; then ### PSMDB 6+ requires "percona-mongodb-mongosh" additionally echo "Downloading mongosh ..." - mongosh_link=$(wget -q --post-data "version_files=${psmdb_latest}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep mongosh) + mongosh_link=$(wget -q --post-data "version_files=percona-server-mongodb-${mongodb_version}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep mongosh) wget -O mongosh.tar.gz ${mongosh_link} tar -xvf mongosh.tar.gz mv percona-mongodb-mongosh* mongosh diff --git a/pmm_qa/tls-ssl-setup/mongodb/mlaunch_ssl_setup.sh b/pmm_qa/tls-ssl-setup/mongodb/mlaunch_ssl_setup.sh index 850def5..177c4b8 100644 --- a/pmm_qa/tls-ssl-setup/mongodb/mlaunch_ssl_setup.sh +++ b/pmm_qa/tls-ssl-setup/mongodb/mlaunch_ssl_setup.sh @@ -14,10 +14,10 @@ fi wget https://raw.githubusercontent.com/percona/pmm-qa/main/pmm-tests/mongodb_user_setup.js ### Detect latest tarball link for specified mongodb_version: 7.0 | 6.0 | 5.0 | 4.4 | 4.2 at the moment -psmdb_latest=$(wget -q --post-data "version=percona-server-mongodb-${mongodb_version}" https://www.percona.com/products-api.php -O - | grep -oP "(?<=value\=\")[^\"]*" | sort -V | tail -1) -psmdb_tarball=$(wget -q --post-data "version_files=${psmdb_latest}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep glibc2\.17-minimal) +#psmdb_latest=$(wget -q --post-data "version=percona-server-mongodb-${mongodb_version}" https://www.percona.com/products-api.php -O - | grep -oP "(?<=value\=\")[^\"]*" | sort -V | tail -1) +psmdb_tarball=$(wget -q --post-data "version_files=percona-server-mongodb-${mongodb_version}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep glibc2\.17-minimal) -echo "Downloading ${psmdb_latest} ..." +echo "Downloading ${mongodb_version} ..." wget -O percona_server_mongodb.tar.gz ${psmdb_tarball} tar -xvf percona_server_mongodb.tar.gz rm percona_server_mongodb.tar.gz* @@ -27,7 +27,7 @@ mv percona-server-mongodb-${mongodb_version}.* psmdb_${mongodb_version} if [[ "$mongodb_version" == "6.0" || "$mongodb_version" == "7.0" ]]; then ### PSMDB 6+ requires "percona-mongodb-mongosh" additionally echo "Downloading mongosh ..." - mongosh_link=$(wget -q --post-data "version_files=${psmdb_latest}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep mongosh) + mongosh_link=$(wget -q --post-data "version_files=percona-server-mongodb-${mongodb_version}&software_files=binary" https://www.percona.com/products-api.php -O - | jq -r '.[] | select(.link | contains("sha") | not) | .link' | grep mongosh) wget -O mongosh.tar.gz ${mongosh_link} tar -xvf mongosh.tar.gz mv percona-mongodb-mongosh* mongosh