LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File make-e2e_node-run-over-distro-bins.patch of Package kubernetes1.6 (Project home:jordimassaguerpla:test_k8s16)

diff --git a/hack/lib/init.sh b/hack/lib/init.sh
index a07f6f2..fc9f0d8 100644
--- a/hack/lib/init.sh
+++ b/hack/lib/init.sh
@@ -46,7 +46,7 @@ source "${KUBE_ROOT}/hack/lib/version.sh"
 source "${KUBE_ROOT}/hack/lib/golang.sh"
 source "${KUBE_ROOT}/hack/lib/etcd.sh"
 
-KUBE_OUTPUT_HOSTBIN="${KUBE_OUTPUT_BINPATH}/$(kube::util::host_platform)"
+KUBE_OUTPUT_HOSTBIN="/usr/bin"
 
 # list of all available group versions.  This should be used when generated code
 # or when starting an API server that you want to have everything.
diff --git a/hack/make-rules/test-e2e-node.sh b/hack/make-rules/test-e2e-node.sh
index 20cea09..4190c19 100755
--- a/hack/make-rules/test-e2e-node.sh
+++ b/hack/make-rules/test-e2e-node.sh
@@ -155,6 +155,6 @@ else
   # Provided for backwards compatibility
   go run test/e2e_node/runner/local/run_local.go --ginkgo-flags="$ginkgoflags" \
     --test-flags="--container-runtime=${runtime} --alsologtostderr --v 4 --report-dir=${artifacts} --node-name $(hostname) \
-    $test_args" --build-dependencies=true 2>&1 | tee -i "${artifacts}/build-log.txt"
+    $test_args --k8s-bin-dir /usr/bin" --build-dependencies=true 2>&1 | tee -i "${artifacts}/build-log.txt"
   exit $?
 fi
diff --git a/test/e2e_node/builder/build.go b/test/e2e_node/builder/build.go
index f22232a..ef60a41 100644
--- a/test/e2e_node/builder/build.go
+++ b/test/e2e_node/builder/build.go
@@ -31,7 +31,7 @@ import (
 var k8sBinDir = flag.String("k8s-bin-dir", "", "Directory containing k8s kubelet binaries.")
 
 var buildTargets = []string{
-	"cmd/kubelet",
+	//"cmd/kubelet",
 	"test/e2e_node/e2e_node.test",
 	"vendor/github.com/onsi/ginkgo/ginkgo",
 }
@@ -53,6 +53,10 @@ func BuildGo() error {
 	return nil
 }
 
+func GetK8sBinDir() string {
+	return *k8sBinDir
+}
+
 func getK8sBin(bin string) (string, error) {
 	// Use commandline specified path
 	if *k8sBinDir != "" {
diff --git a/test/e2e_node/services/services.go b/test/e2e_node/services/services.go
index c206a85..7019af8 100644
--- a/test/e2e_node/services/services.go
+++ b/test/e2e_node/services/services.go
@@ -141,6 +141,11 @@ func (e *E2EServices) startInternalServices() (*server, error) {
 	}
 	// Pass all flags into the child process, so that it will see the same flag set.
 	startCmd := exec.Command(testBin, append([]string{"--run-services-mode"}, os.Args[1:]...)...)
+
+	if build.GetK8sBinDir() != "" {
+		startCmd.Args = append(startCmd.Args, fmt.Sprintf("--k8s-bin-dir=%v", build.GetK8sBinDir()))
+	}
+
 	server := newServer("services", startCmd, nil, nil, getServicesHealthCheckURLs(), servicesLogFile, e.monitorParent, false)
 	return server, server.start()
 }