Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
erebe authored Dec 17, 2024
1 parent 6feb097 commit 1ae15b6
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,13 @@

repo="Qovery/qovery-cli"
output_tgz="/tmp/qovery.tgz"
dest_binary="/usr/local/bin"
if ! command -v sudo 2>&1 >/dev/null
then
dest_binary="."
else
dest_binary="/usr/local/bin"
fi

os=$(uname | tr '[:upper:]' '[:lower:]')
case "$(uname -m)" in
x86_64 | amd64)
Expand All @@ -38,11 +44,11 @@
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)"
if [ "$EUID" -ne 0 ]
if ! command -v sudo 2>&1 >/dev/null
then
sudo tar -xzf $output_tgz -C $dest_binary qovery
tar -xzf $output_tgz -C $dest_binary qovery
else
tar -xzf $output_tgz -C $dest_binary qovery
sudo tar -xzf $output_tgz -C $dest_binary qovery
fi
rm -f $output_tgz

Expand Down

0 comments on commit 1ae15b6

Please sign in to comment.