From 25c2220ae3f35d7f0b175d65003e386224209d40 Mon Sep 17 00:00:00 2001 From: Kiichiro YUKAWA Date: Fri, 1 Nov 2024 18:13:01 +0900 Subject: [PATCH] Fix installation command for arm64 (#2729) * :bug: Fix installation command for arm64 Signed-off-by: vankichi * :bug: Fix typo Signed-off-by: vankichi * :bug: Fix Signed-off-by: vankichi --------- Signed-off-by: vankichi --- Makefile.d/helm.mk | 6 ++++-- Makefile.d/k8s.mk | 3 ++- Makefile.d/kind.mk | 3 ++- Makefile.d/tools.mk | 3 ++- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/Makefile.d/helm.mk b/Makefile.d/helm.mk index c468abe6c7..a665eda631 100644 --- a/Makefile.d/helm.mk +++ b/Makefile.d/helm.mk @@ -28,7 +28,8 @@ helm-docs/install: $(BINDIR)/helm-docs $(BINDIR)/helm-docs: mkdir -p $(BINDIR) - TAR_NAME=helm-docs_$(HELM_DOCS_VERSION)_$(UNAME)_$(ARCH).tar.gz \ + $(eval DARCH := $(subst aarch64,arm64,$(ARCH))) + TAR_NAME=helm-docs_$(HELM_DOCS_VERSION)_$(UNAME)_$(DARCH).tar.gz \ && cd $(TEMP_DIR) \ && curl -fsSL "https://github.com/norwoodj/helm-docs/releases/download/v$(HELM_DOCS_VERSION)/$${TAR_NAME}" -o "$(TEMP_DIR)/$${TAR_NAME}"\ && tar xzvf "$(TEMP_DIR)/$${TAR_NAME}" \ @@ -156,8 +157,9 @@ yq/install: $(BINDIR)/yq $(BINDIR)/yq: mkdir -p $(BINDIR) + $(eval DARCH := $(subst aarch64,arm64,$(ARCH))) cd $(TEMP_DIR) \ - && curl -fsSL https://github.com/mikefarah/yq/releases/download/$(YQ_VERSION)/yq_$(OS)_$(subst x86_64,amd64,$(shell echo $(ARCH) | tr '[:upper:]' '[:lower:]')) -o $(BINDIR)/yq \ + && curl -fsSL https://github.com/mikefarah/yq/releases/download/$(YQ_VERSION)/yq_$(OS)_$(subst x86_64,amd64,$(shell echo $(DARCH) | tr '[:upper:]' '[:lower:]')) -o $(BINDIR)/yq \ && chmod a+x $(BINDIR)/yq .PHONY: helm/schema/crd/all diff --git a/Makefile.d/k8s.mk b/Makefile.d/k8s.mk index 8693f9d2fe..e2dbf87495 100644 --- a/Makefile.d/k8s.mk +++ b/Makefile.d/k8s.mk @@ -534,8 +534,9 @@ telepresence/install: $(BINDIR)/telepresence $(BINDIR)/telepresence: mkdir -p $(BINDIR) + $(eval DARCH := $(subst aarch64,arm64,$(ARCH))) cd $(TEMP_DIR) \ - && curl -fsSL "https://app.getambassador.io/download/tel2oss/releases/download/v$(TELEPRESENCE_VERSION)/telepresence-$(OS)-$(subst x86_64,amd64,$(shell echo $(ARCH) | tr '[:upper:]' '[:lower:]'))" -o $(BINDIR)/telepresence \ + && curl -fsSL "https://app.getambassador.io/download/tel2oss/releases/download/v$(TELEPRESENCE_VERSION)/telepresence-$(OS)-$(subst x86_64,amd64,$(shell echo $(DARCH) | tr '[:upper:]' '[:lower:]'))" -o $(BINDIR)/telepresence \ && chmod a+x $(BINDIR)/telepresence .PHONY: telepresence/swap/agent-ngt diff --git a/Makefile.d/kind.mk b/Makefile.d/kind.mk index a2f15b5217..b7ca9605c1 100644 --- a/Makefile.d/kind.mk +++ b/Makefile.d/kind.mk @@ -19,7 +19,8 @@ kind/install: $(BINDIR)/kind $(BINDIR)/kind: mkdir -p $(BINDIR) - curl -fsSL https://github.com/kubernetes-sigs/kind/releases/download/v$(KIND_VERSION)/kind-$(OS)-$(subst x86_64,amd64,$(shell echo $(ARCH) | tr '[:upper:]' '[:lower:]')) -o $(BINDIR)/kind + $(eval DARCH := $(subst aarch64,arm64,$(ARCH))) + curl -fsSL https://github.com/kubernetes-sigs/kind/releases/download/v$(KIND_VERSION)/kind-$(OS)-$(subst x86_64,amd64,$(shell echo $(DARCH) | tr '[:upper:]' '[:lower:]')) -o $(BINDIR)/kind chmod a+x $(BINDIR)/kind .PHONY: kind/start diff --git a/Makefile.d/tools.mk b/Makefile.d/tools.mk index f1071faf00..e18836ccc5 100644 --- a/Makefile.d/tools.mk +++ b/Makefile.d/tools.mk @@ -71,7 +71,8 @@ $(BINDIR)/reviewdog: kubectl/install: $(BINDIR)/kubectl $(BINDIR)/kubectl: - curl -fsSL "https://dl.k8s.io/release/$(KUBECTL_VERSION)/bin/$(OS)/$(subst x86_64,amd64,$(shell echo $(ARCH) | tr '[:upper:]' '[:lower:]'))/kubectl" -o $(BINDIR)/kubectl + $(eval DARCH := $(subst aarch64,arm64,$(ARCH))) + curl -fsSL "https://dl.k8s.io/release/$(KUBECTL_VERSION)/bin/$(OS)/$(subst x86_64,amd64,$(shell echo $(DARCH) | tr '[:upper:]' '[:lower:]'))/kubectl" -o $(BINDIR)/kubectl chmod a+x $(BINDIR)/kubectl .PHONY: textlint/install