You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
1010 B
29 lines
1010 B
#!/usr/bin/env bash
|
|
|
|
set -e
|
|
set -u
|
|
set -o pipefail
|
|
|
|
# To get the latest version, see <https://www.ubuntuupdates.org/ppa/google_chrome?dist=stable>
|
|
CHROME_VERSION='103.0.5060.53-1'
|
|
CHROME_BINARY="google-chrome-stable_${CHROME_VERSION}_amd64.deb"
|
|
CHROME_BINARY_URL="https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/${CHROME_BINARY}"
|
|
|
|
# To retrieve this checksum, run the `wget` and `shasum` commands below
|
|
CHROME_BINARY_SHA512SUM='36f4e79f46cb71c1431dccf1489f5f8e89d35204a717a4618c7f6f638123ddc2b37bd5cbd00498be8f84c7713149f2faa447cb6da3518be1cb9703e99d110e1a'
|
|
|
|
wget -O "${CHROME_BINARY}" -t 5 "${CHROME_BINARY_URL}"
|
|
|
|
if [[ $(shasum -a 512 "${CHROME_BINARY}" | cut '--delimiter= ' -f1) != "${CHROME_BINARY_SHA512SUM}" ]]
|
|
then
|
|
echo "Google Chrome binary checksum did not match."
|
|
exit 1
|
|
else
|
|
echo "Google Chrome binary checksum verified."
|
|
fi
|
|
|
|
(sudo dpkg -i "${CHROME_BINARY}" || sudo apt-get -fy install)
|
|
|
|
rm -rf "${CHROME_BINARY}"
|
|
|
|
printf '%s\n' "CHROME ${CHROME_VERSION} configured"
|
|
|