From 18a58b8f9b8514c2485a9a0d19668263272eb8ca Mon Sep 17 00:00:00 2001 From: Yolanda Robla Date: Fri, 24 May 2019 19:25:57 +0200 Subject: [PATCH] Modify installation of kustomize Download an already compiled kustomize version, to pin to an stable release instead of latest. Change-Id: I1afecb6aa35a0ef07cb7a7a8acefeceb029e3dcb --- Makefile | 2 +- utils/install_dependencies.sh | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) create mode 100755 utils/install_dependencies.sh diff --git a/Makefile b/Makefile index 4f11ee0..0f1cc1a 100644 --- a/Makefile +++ b/Makefile @@ -45,7 +45,7 @@ clean: dependencies: @echo "Installing dependencies" - @GOPATH=$(GOPATH) GOBIN=$(GOBIN) go get sigs.k8s.io/kustomize + @./utils/install_dependencies.sh @wget -A "openshift-client-linux-4*\.tar\.gz" -r -np -nc -nd -l1 --no-check-certificate -e robots=off https://mirror.openshift.com/pub/openshift-v4/clients/ocp/latest/ -P /tmp/ @sudo tar -xvf /tmp/openshift-client-linux-4*.tar.gz -C /usr/local/bin/ oc @rm -f /tmp/openshift-client-linux-4*.tar.gz diff --git a/utils/install_dependencies.sh b/utils/install_dependencies.sh new file mode 100755 index 0000000..4c8af30 --- /dev/null +++ b/utils/install_dependencies.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +URL=$(curl https://api.github.com/repos/kubernetes-sigs/kustomize/releases/latest |grep browser_download | grep linux | cut -d '"' -f 4) +sudo -E curl -L $URL -o /usr/local/bin/kustomize +sudo chmod u+x /usr/local/bin/kustomize + +wget -A "openshift-client-linux-4*\.tar\.gz" -r -np -nc -nd -l1 --no-check-certificate -e robots=off https://mirror.openshift.com/pub/openshift-v4/clients/ocp/latest/ -P /tmp/ +sudo tar -xvf /tmp/openshift-client-linux-4*.tar.gz -C /usr/local/bin/ oc +rm -f /tmp/openshift-client-linux-4*.tar.gz + -- 2.16.6