install Kind to GOENV/bin
This commit is contained in:
parent
82bf0d90ed
commit
b8e5567e91
4
Makefile
4
Makefile
|
|
@ -34,7 +34,7 @@ ifdef CDP_PULL_REQUEST_NUMBER
|
|||
CDP_TAG := -${CDP_BUILD_VERSION}
|
||||
endif
|
||||
|
||||
|
||||
KIND_PATH := $(GOPATH)/bin
|
||||
PATH := $(GOPATH)/bin:$(PATH)
|
||||
SHELL := env PATH=$(PATH) $(SHELL)
|
||||
|
||||
|
|
@ -98,7 +98,7 @@ e2e-build:
|
|||
e2e-tools:
|
||||
wget https://github.com/kubernetes-sigs/kind/releases/download/0.2.1/kind-linux-amd64
|
||||
chmod +x kind-linux-amd64
|
||||
mv kind-linux-amd64 /tmp/kind
|
||||
mv kind-linux-amd64 $(KIND_PATH)
|
||||
|
||||
e2e-run: docker
|
||||
e2e/run.sh
|
||||
|
|
|
|||
|
|
@ -6,16 +6,13 @@ set -o nounset
|
|||
set -o pipefail
|
||||
IFS=$'\n\t'
|
||||
|
||||
export PATH=$PATH:/tmp/kind
|
||||
echo $PATH
|
||||
ls -al /tmp/kind
|
||||
|
||||
readonly cluster_name="postgres-operator-e2e-tests"
|
||||
readonly operator_image=$(docker images --filter=reference="registry.opensource.zalan.do/acid/postgres-operator" --format "{{.Repository}}:{{.Tag}}" | head -1)
|
||||
readonly e2e_test_image=${cluster_name}
|
||||
readonly kind_api_server_port=6443 # well-known in the 'kind' codebase
|
||||
readonly kubeconfig_path="./e2e/kind-config-${cluster_name}"
|
||||
|
||||
alias kind="${GOPATH}/bin/kind-linux-amd64"
|
||||
# avoid interference with previous test runs
|
||||
if [[ $(kind get clusters | grep "^${cluster_name}*") != "" ]]
|
||||
then
|
||||
|
|
@ -36,4 +33,5 @@ sed -i "s/server.*$/server: https:\/\/$kind_api_server/g" ${kubeconfig_path}
|
|||
docker run --rm --mount type=bind,source="$(realpath ${kubeconfig_path})",target=/root/.kube/config -e OPERATOR_IMAGE=${operator_image} ${e2e_test_image}
|
||||
|
||||
kind delete cluster --name ${cluster_name}
|
||||
unalias kind
|
||||
rm -rf ${kubeconfig_path}
|
||||
|
|
|
|||
Loading…
Reference in New Issue