From eb76d709d57ad46e306c60b200a7376b22d07a5d Mon Sep 17 00:00:00 2001 From: Mike Danese Date: Thu, 10 Sep 2020 19:47:22 -0700 Subject: [PATCH] use kube::util::find-binary to find kubectl To centralize binary selection in k/k. Also drop the e2e.test copying which is no longer needed according to the comment. --- hack/ci/e2e-k8s.sh | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/hack/ci/e2e-k8s.sh b/hack/ci/e2e-k8s.sh index d91fe6c755..2fc5777eb5 100755 --- a/hack/ci/e2e-k8s.sh +++ b/hack/ci/e2e-k8s.sh @@ -71,12 +71,8 @@ build_with_bazel() { bazel shutdown || true pkill ^bazel || true - # ensure the e2e script will find our binaries ... - # https://github.com/kubernetes/kubernetes/issues/68306 - # TODO: remove this, it was fixed in 1.13+ - mkdir -p '_output/bin/' - cp 'bazel-bin/test/e2e/e2e.test' '_output/bin/' - PATH="$(dirname "$(find "${PWD}/bazel-bin/" -name kubectl -type f)"):${PATH}" + local -r kubectl_path="$(source hack/lib/util.sh; kube::util::find-binary '.test')" '_output/bin/' + PATH="$(dirname "\""${kubectl_path}"\""):${PATH}" export PATH }