diff --git a/hack/install-etcd.sh b/hack/install-etcd.sh index fb4bed85364..5acb177babd 100755 --- a/hack/install-etcd.sh +++ b/hack/install-etcd.sh @@ -27,4 +27,4 @@ source "${KUBE_ROOT}/hack/lib/init.sh" FOUND="$(echo "${PATH}" | sed 's/:/\n/g' | grep -q "^${KUBE_ROOT}/third_party/etcd$" || true)" kube::etcd::install -test -n "${FOUND}" || echo " PATH=\"\$PATH:${KUBE_ROOT}/third_party/etcd\"" +test -n "${FOUND}" || echo "export PATH=\"\${PATH}:${KUBE_ROOT}/third_party/etcd\"" diff --git a/hack/jenkins/benchmark-dockerized.sh b/hack/jenkins/benchmark-dockerized.sh index 2adda151df3..a01dee72279 100755 --- a/hack/jenkins/benchmark-dockerized.sh +++ b/hack/jenkins/benchmark-dockerized.sh @@ -48,7 +48,6 @@ if [ -n "${KUBE_HACK_TOOLS_GOTOOLCHAIN:-}" ]; then hack_tools_gotoolchain="${KUBE_HACK_TOOLS_GOTOOLCHAIN}"; fi GOTOOLCHAIN="${hack_tools_gotoolchain}" go -C "${KUBE_ROOT}/hack/tools" install github.com/cespare/prettybench -GOTOOLCHAIN="${hack_tools_gotoolchain}" go -C "${KUBE_ROOT}/hack/tools" install gotest.tools/gotestsum # Disable the Go race detector. export KUBE_RACE=" " diff --git a/hack/jenkins/test-cmd-dockerized.sh b/hack/jenkins/test-cmd-dockerized.sh index cc7ed476c6c..07baa4f7a07 100755 --- a/hack/jenkins/test-cmd-dockerized.sh +++ b/hack/jenkins/test-cmd-dockerized.sh @@ -19,20 +19,11 @@ set -o nounset set -o pipefail set -o xtrace -# Runs test-cmd, -# producing JUnit-style XML test -# reports in ${WORKSPACE}/artifacts. This script is intended to be run from -# kubekins-test container with a kubernetes repo mapped in. See -# k8s.io/test-infra/scenarios/kubernetes_verify.py +# Runs test-cmd, intended to be run in prow.k8s.io +set -x; -export PATH=${GOPATH}/bin:${PWD}/third_party/etcd:/usr/local/go/bin:${PATH} - -# Set artifacts directory -export ARTIFACTS=${ARTIFACTS:-"${WORKSPACE}/artifacts"} - -cd "${GOPATH}/src/k8s.io/kubernetes" - -./hack/install-etcd.sh +# TODO: make test-cmd should handle this automatically +source ./hack/install-etcd.sh make test-cmd diff --git a/hack/jenkins/test-dockerized.sh b/hack/jenkins/test-dockerized.sh index 0bc747cb348..72b6884b30b 100755 --- a/hack/jenkins/test-dockerized.sh +++ b/hack/jenkins/test-dockerized.sh @@ -19,32 +19,14 @@ set -o nounset set -o pipefail set -o xtrace -# Runs test-cmd and test-integration, -# producing JUnit-style XML test -# reports in ${WORKSPACE}/artifacts. This script is intended to be run from -# kubekins-test container with a kubernetes repo mapped in. See -# k8s.io/test-infra/scenarios/kubernetes_verify.py +# Runs test-cmd and test-integration, intended to be run in prow.k8s.io +set -x; -export PATH=${GOPATH}/bin:${PWD}/third_party/etcd:/usr/local/go/bin:${PATH} +# TODO: make test-integration should handle this automatically +source ./hack/install-etcd.sh -# Install tools we need -hack_tools_gotoolchain="${GOTOOLCHAIN:-}" -if [ -n "${KUBE_HACK_TOOLS_GOTOOLCHAIN:-}" ]; then - hack_tools_gotoolchain="${KUBE_HACK_TOOLS_GOTOOLCHAIN}"; -fi -GOTOOLCHAIN="${hack_tools_gotoolchain}" go -C "./hack/tools" install gotest.tools/gotestsum - -# Disable coverage report -export KUBE_COVER="n" -# Set artifacts directory -export ARTIFACTS=${ARTIFACTS:-"${WORKSPACE}/artifacts"} # Save the verbose stdout as well. export KUBE_KEEP_VERBOSE_TEST_OUTPUT=y export LOG_LEVEL=4 - -cd "${GOPATH}/src/k8s.io/kubernetes" - -./hack/install-etcd.sh - make test-cmd make test-integration diff --git a/hack/jenkins/test-integration-dockerized.sh b/hack/jenkins/test-integration-dockerized.sh index 6b9adff8dfa..ec856abc3bd 100755 --- a/hack/jenkins/test-integration-dockerized.sh +++ b/hack/jenkins/test-integration-dockerized.sh @@ -19,27 +19,11 @@ set -o nounset set -o pipefail set -o xtrace -# Runs test-integration, -# producing JUnit-style XML test -# reports in ${WORKSPACE}/artifacts. This script is intended to be run from -# kubekins-test container with a kubernetes repo mapped in. See -# k8s.io/test-infra/scenarios/kubernetes_verify.py +# Runs test-integration +# This script is intended to be run from prow.k8s.io +set -x; -export PATH=${GOPATH}/bin:${PWD}/third_party/etcd:/usr/local/go/bin:${PATH} +# TODO: make test-integration should handle this automatically +source ./hack/install-etcd.sh -# Install tools we need -go -C "./hack/tools" install gotest.tools/gotestsum - -# Disable coverage report -export KUBE_COVER="n" -# Set artifacts directory -export ARTIFACTS=${ARTIFACTS:-"${WORKSPACE}/artifacts"} -# Save the verbose stdout as well. -export KUBE_KEEP_VERBOSE_TEST_OUTPUT=y -export LOG_LEVEL=4 - -cd "${GOPATH}/src/k8s.io/kubernetes" - -./hack/install-etcd.sh - -make test-integration +make test-integration KUBE_KEEP_VERBOSE_TEST_OUTPUT=y LOG_LEVEL=4