mirror of
https://github.com/vmware-tanzu/pinniped.git
synced 2026-11-08 04:19:07 +00:00
fly installer update.
Signed-off-by: Volkan Özçelik <volkan.ozcelik@broadcom.com>
This commit is contained in:
1 file changed
+10
-4
+10
-4
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright 2020-2025 the Pinniped contributors. All Rights Reserved.
|
||||
# Copyright 2020-2026 the Pinniped contributors. All Rights Reserved.
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
set -euo pipefail
|
||||
@@ -10,9 +10,15 @@ script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
# Define some env vars
|
||||
source "$script_dir/fly-helpers.sh"
|
||||
|
||||
# Install the fly cli if needed
|
||||
if [[ ! -f "$FLY_CLI" ]]; then
|
||||
curl -fL "$CONCOURSE_URL/api/v1/cli?arch=amd64&platform=darwin" -o "$FLY_CLI"
|
||||
# Install the fly cli if missing or unable to run on this platform.
|
||||
if [[ ! -x "$FLY_CLI" ]] || ! "$FLY_CLI" --version >/dev/null 2>&1; then
|
||||
fly_arch="$(uname -m)"
|
||||
case "$fly_arch" in
|
||||
x86_64) fly_arch="amd64" ;;
|
||||
aarch64) fly_arch="arm64" ;;
|
||||
esac
|
||||
fly_platform="$(uname -s | tr '[:upper:]' '[:lower:]')"
|
||||
curl -fL "$CONCOURSE_URL/api/v1/cli?arch=${fly_arch}&platform=${fly_platform}" -o "$FLY_CLI"
|
||||
chmod 755 "$FLY_CLI"
|
||||
fi
|
||||
|
||||
|
||||
Reference in new issue
Block a user