diff --git a/mini-e2e-helm.groovy b/mini-e2e-helm.groovy index cd0542856..10813bc63 100644 --- a/mini-e2e-helm.groovy +++ b/mini-e2e-helm.groovy @@ -128,6 +128,16 @@ node('cico-workspace') { ssh 'cd /opt/build/go/src/github.com/ceph/ceph-csi && make containerized-build CONTAINER_CMD=podman TARGET=e2e.test' } stage("deploy k8s-${k8s_version} and rook") { + def rook_version = sh( + script: 'ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no root@${CICO_NODE} \'source /opt/build/go/src/github.com/ceph/ceph-csi/build.env && echo ${ROOK_VERSION}\'', + returnStdout: true + ).trim() + + if (rook_version != '') { + // single-node-k8s.sh pushes the image into minikube + podman_pull(ci_registry, "rook/ceph:${rook_version}") + } + timeout(time: 30, unit: 'MINUTES') { ssh "./single-node-k8s.sh --k8s-version=${k8s_release}" } diff --git a/mini-e2e.groovy b/mini-e2e.groovy index b14b57f89..2618c8eec 100644 --- a/mini-e2e.groovy +++ b/mini-e2e.groovy @@ -125,6 +125,16 @@ node('cico-workspace') { ssh "cd /opt/build/go/src/github.com/ceph/ceph-csi && make containerized-build CONTAINER_CMD=podman TARGET=e2e.test ENV_CSI_IMAGE_NAME=${ci_registry}/ceph-csi USE_PULLED_IMAGE=yes" } stage("deploy k8s-${k8s_version} and rook") { + def rook_version = sh( + script: 'ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no root@${CICO_NODE} \'source /opt/build/go/src/github.com/ceph/ceph-csi/build.env && echo ${ROOK_VERSION}\'', + returnStdout: true + ).trim() + + if (rook_version != '') { + // single-node-k8s.sh pushes the image into minikube + podman_pull(ci_registry, "rook/ceph:${rook_version}") + } + timeout(time: 30, unit: 'MINUTES') { ssh "./single-node-k8s.sh --k8s-version=${k8s_release}" } diff --git a/single-node-k8s.sh b/single-node-k8s.sh index 184ce9549..ed95911c9 100755 --- a/single-node-k8s.sh +++ b/single-node-k8s.sh @@ -129,6 +129,12 @@ install_minikube ./podman2minikube.sh "quay.io/cephcsi/cephcsi:${CSI_IMAGE_VERSION}" +# incase rook/ceph is available on the local system, push it into the VM +if podman inspect "rook/ceph:${ROOK_VERSION}" +then + ./podman2minikube.sh "rook/ceph:${ROOK_VERSION}" +fi + deploy_rook # running e2e.test requires librados and librbd diff --git a/upgrade-tests.groovy b/upgrade-tests.groovy index a9a47b118..956404750 100644 --- a/upgrade-tests.groovy +++ b/upgrade-tests.groovy @@ -125,6 +125,16 @@ node('cico-workspace') { ssh 'cd /opt/build/go/src/github.com/ceph/ceph-csi && make containerized-build CONTAINER_CMD=podman TARGET=e2e.test' } stage("deploy k8s-${k8s_version} and rook") { + def rook_version = sh( + script: 'ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no root@${CICO_NODE} \'source /opt/build/go/src/github.com/ceph/ceph-csi/build.env && echo ${ROOK_VERSION}\'', + returnStdout: true + ).trim() + + if (rook_version != '') { + // single-node-k8s.sh pushes the image into minikube + podman_pull(ci_registry, "rook/ceph:${rook_version}") + } + timeout(time: 30, unit: 'MINUTES') { ssh "./single-node-k8s.sh --k8s-version=${k8s_release}" }