File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -39,6 +39,32 @@ tmp_bin=/tmp/cr-tests-bin
3939)
4040export KUBEBUILDER_ASSETS=" $( ${tmp_bin} /setup-envtest use --use-env -p path " ${ENVTEST_K8S_VERSION} " ) "
4141
42+ # HACK
43+ k8s_clone_dir=$tmp_root /kubernetes
44+ (
45+ k8s_repo_url=https://github.com/kubernetes/kubernetes.git
46+
47+ echo " Cloning Kube repository from $k8s_repo_url ..."
48+ git clone $k8s_repo_url $k8s_clone_dir
49+
50+ cd $k8s_clone_dir
51+ echo " Building Kube from source code..."
52+ make
53+ )
54+ k8s_bin_dir=$(
55+ k8s_output_dir=${k8s_clone_dir} /_output/local/go/bin
56+ if [ -d " ${k8s_output_dir} " ]; then
57+ cd ${k8s_output_dir}
58+ pwd
59+ else
60+ echo " Directory ${k8s_output_dir} does not exist."
61+ exit 1
62+ fi
63+ )
64+ echo " Replacing kube-apiserver binary from ${k8s_bin_dir} to ${KUBEBUILDER_ASSETS} "
65+ cp -f " ${k8s_bin_dir} /kube-apiserver" " ${KUBEBUILDER_ASSETS} /kube-apiserver"
66+ # END OF HACK
67+
4268# Run tests.
4369${hack_dir} /test-all.sh
4470
You can’t perform that action at this time.
0 commit comments