[macos] simplify "brew_smart_install" helper (#8639)

* [macos] homebrew: use hardcoded condition for jq installation

we cannot use "jq" if we are asked to install "jq"

* [macos] always use "brew install"

* [macos] add retries to "get_github_package_download_url" helper

* [macos] add retries to chrome install script

* [macos] add retries to OpenJDK install script

* [macos] add retries to miniconda installer

* Update images/macos/provision/core/openjdk.sh

Co-authored-by: Vasilii Polikarpov <126792224+vpolikarpov-akvelon@users.noreply.github.com>

* fix copy-paste error

* Update images/macos/provision/core/openjdk.sh

Co-authored-by: Vasilii Polikarpov <126792224+vpolikarpov-akvelon@users.noreply.github.com>

* Update images/macos/provision/core/openjdk.sh

Co-authored-by: Vasilii Polikarpov <126792224+vpolikarpov-akvelon@users.noreply.github.com>

---------

Co-authored-by: Vasilii Polikarpov <126792224+vpolikarpov-akvelon@users.noreply.github.com>
This commit is contained in:
ilia-shipitsin
2023-10-26 15:17:57 +02:00
committed by GitHub
parent 7ca7296ba5
commit 883df0594b
4 changed files with 55 additions and 89 deletions

View File

@@ -14,7 +14,8 @@ echo "Google Chrome version is $FULL_CHROME_VERSION"
# Get Google Chrome versions information
CHROME_PLATFORM="mac-$arch"
CHROME_VERSIONS_URL="https://googlechromelabs.github.io/chrome-for-testing/latest-patch-versions-per-build-with-downloads.json"
CHROME_VERSIONS_JSON=$(curl -fsSL "${CHROME_VERSIONS_URL}")
download_with_retries "$CHROME_VERSIONS_URL" "/tmp" "latest-patch-versions-per-build-with-downloads.json"
CHROME_VERSIONS_JSON=$(cat /tmp/latest-patch-versions-per-build-with-downloads.json)
# Download and unpack the latest release of Chrome Driver
CHROMEDRIVER_VERSION=$(echo "${CHROME_VERSIONS_JSON}" | jq -r '.builds["'"$CHROME_VERSION"'"].version')