Fix: #2534 can't exit make when error occurs in curl (#2540)

- use `curl -sS` to show error
- use `set -eo pipefail` to exit `make` when error occurs in `curl`
This commit is contained in:
yuyicai
2021-10-24 09:59:24 +08:00
committed by GitHub
parent cf039e27e5
commit b2fb9fc618
+2 -2
View File
@@ -332,9 +332,9 @@ KUSTOMIZE_VERSION ?= 3.8.2
kustomize:
ifeq (, $(shell kustomize version | grep $(KUSTOMIZE_VERSION)))
@{ \
set -e ;\
set -eo pipefail ;\
echo 'installing kustomize-v$(KUSTOMIZE_VERSION) into $(GOBIN)' ;\
curl -s https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh | bash -s $(KUSTOMIZE_VERSION) $(GOBIN);\
curl -sS https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh | bash -s $(KUSTOMIZE_VERSION) $(GOBIN);\
echo 'Install succeed' ;\
}
KUSTOMIZE=$(GOBIN)/kustomize