qovery-cli
qovery-cli copied to clipboard
Update qovery install script to account for arm64 architecture
What would you like to be added: Update qovery install script to account for arm64 architecture, and not hardcode amd64
an update proposal to the script:
#!/usr/bin/env bash
set -e
#set -x
echo "##################################"
echo "# #"
echo "# QOVERY CLI INSTALL #"
echo "# #"
echo "##################################"
echo ""
repo="Qovery/qovery-cli"
output_tgz="/tmp/qovery.tgz"
dest_binary="/usr/local/bin"
os=$(uname | tr '[:upper:]' '[:lower:]')
arch=$(uname -m)
if [ "$arch" != "aarch64" ]; then
arch="arm64"
else
arch="amd64"
fi
echo "[+] Downloading Qovery CLI archive..."
latest_tag=$(curl --silent "https://api.github.com/repos/$repo/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
version=$(echo $latest_tag | sed 's/^v//')
test -f $output_tgz && rm -f $output_tgz
curl -o $output_tgz -sOL "https://github.com/${repo}/releases/download/${latest_tag}/qovery-cli_${version}_${os}_${arch}.tar.gz"
echo "[+] Uncompressing qovery binary in $dest_binary directory (sudo permissions are required)"
sudo tar -xzf $output_tgz -C $dest_binary qovery
rm -f $output_tgz
echo -e "\nQovery CLI is installed, you can now use 'qovery' command line"
Why is this needed: when running the installer on an arm arch, the qovery doesn't work, since the installer didn't fetch the arm64 build
cc @deimosfr - can you take a look?
Hitting the same issue. It's fine on Mac laptops, probably thanks to Rosetta, but not on our CI as it runs on ARM machines. We're using that for now: https://gist.github.com/jbbarth/0356bdfa2e703a1f218c79731287200d
Hey @jbbarth - thanks for bumping this one. I share it with the team
internal track https://qovery.atlassian.net/browse/COR-891
This was fixed a month ago, sorry for the late reply. The script has been updated to manage both amd64 and arm64 architectures