Skip to content

Commit

Permalink
Fix install script for M1 mac (#828)
Browse files Browse the repository at this point in the history
  • Loading branch information
berndverst authored Nov 10, 2021
1 parent 78db31a commit 99cb9c1
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions install/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ getSystemInfo() {
}

verifySupported() {
releaseTag=$1
local supported=(darwin-amd64 linux-amd64 linux-arm linux-arm64)
local current_osarch="${OS}-${ARCH}"

Expand All @@ -51,7 +52,7 @@ verifySupported() {
done

if [ "$current_osarch" == "darwin-arm64" ]; then
if isReleaseAvailable; then
if isReleaseAvailable $releaseTag; then
return
else
echo "The darwin_arm64 arch has no native binary for this version of Dapr, however you can use the amd64 version so long as you have rosetta installed"
Expand Down Expand Up @@ -207,9 +208,6 @@ trap "fail_trap" EXIT

getSystemInfo
checkHttpRequestCLI
verifySupported
checkExistingDapr


if [ -z "$1" ]; then
echo "Getting the latest Dapr CLI..."
Expand All @@ -218,6 +216,9 @@ else
ret_val=v$1
fi

verifySupported $ret_val
checkExistingDapr

echo "Installing $ret_val Dapr CLI..."

downloadFile $ret_val
Expand Down

0 comments on commit 99cb9c1

Please sign in to comment.