1212 - " !deploy/iso/**"
1313env :
1414 GOPROXY : https://proxy.golang.org
15- GO_VERSION : ' 1.19.3 '
15+ GO_VERSION : ' 1.19.5 '
1616permissions :
1717 contents : read
1818
@@ -290,6 +290,125 @@ jobs:
290290 if [ "$numPass" -lt 36 ];then echo "*** Failed to pass at least 36 ! ***";exit 2;fi
291291 if [ "$numPass" -eq 0 ];then echo "*** Passed! ***";exit 0;fi
292292
293+ functional_docker_rootless_containerd_ubuntu :
294+ permissions :
295+ contents : none
296+ needs : [build_minikube]
297+ env :
298+ TIME_ELAPSED : time
299+ JOB_NAME : " functional_docker_rootless_containerd_ubuntu"
300+ GOPOGH_RESULT : " "
301+ SHELL : " /bin/bash" # To prevent https://github.com/kubernetes/minikube/issues/6643
302+ DEBIAN_FRONTEND : noninteractive
303+ # ubuntu-22.04 is needed for cgroup v2
304+ runs-on : ubuntu-22.04
305+ steps :
306+ - name : Install kubectl
307+ shell : bash
308+ run : |
309+ curl -LO "https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl"
310+ sudo install kubectl /usr/local/bin/kubectl
311+ kubectl version --client=true
312+ # https://rootlesscontaine.rs/getting-started/common/cgroup2/
313+ - name : Set up cgroup v2 delegation
314+ run : |
315+ sudo mkdir -p /etc/systemd/system/[email protected] 316+ cat <<EOF | sudo tee /etc/systemd/system/[email protected] /delegate.conf 317+ [Service]
318+ Delegate=cpu cpuset io memory pids
319+ EOF
320+ sudo systemctl daemon-reload
321+ - name : Set up Rootless Docker
322+ run : |
323+ sudo apt-get remove moby-engine-*
324+ curl https://get.docker.com | sudo sh
325+ dockerd-rootless-setuptool.sh install -f
326+ docker context use rootless
327+ - name : Docker Info
328+ shell : bash
329+ run : |
330+ echo "--------------------------"
331+ docker version || true
332+ echo "--------------------------"
333+ docker info || true
334+ echo "--------------------------"
335+ docker system df || true
336+ echo "--------------------------"
337+ docker system info --format='{{json .}}'|| true
338+ echo "--------------------------"
339+ docker ps || true
340+ echo "--------------------------"
341+ - uses : actions/setup-go@d0a58c1c4d2b25278816e339b944508c875f3613
342+ with :
343+ go-version : ${{env.GO_VERSION}}
344+ - name : Install gopogh
345+
346+ shell : bash
347+ run : |
348+ curl -LO https://github.com/medyagh/gopogh/releases/download/v0.13.0/gopogh-linux-amd64
349+ sudo install gopogh-linux-amd64 /usr/local/bin/gopogh
350+ - name : Download Binaries
351+ uses : actions/download-artifact@9782bd6a9848b53b110e712e20e42d89988822b7
352+ with :
353+ name : minikube_binaries
354+ path : minikube_binaries
355+ - name : Run Integration Test
356+ continue-on-error : false
357+ # bash {0} to allow test to continue to next step. in case of
358+ shell : bash {0}
359+ run : |
360+ cd minikube_binaries
361+ mkdir -p report
362+ mkdir -p testhome
363+ chmod a+x e2e-*
364+ chmod a+x minikube-*
365+ sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
366+ sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
367+ MINIKUBE_HOME=$(pwd)/testhome ./minikube-linux-amd64 delete --all --purge
368+ START_TIME=$(date -u +%s)
369+ KUBECONFIG=$(pwd)/testhome/kubeconfig MINIKUBE_HOME=$(pwd)/testhome ./e2e-linux-amd64 -minikube-start-args="--vm-driver=docker --rootless --container-runtime=containerd" -test.run TestFunctional -test.timeout=30m -test.v -timeout-multiplier=1.5 -binary=./minikube-linux-amd64 2>&1 | tee ./report/testout.txt
370+ END_TIME=$(date -u +%s)
371+ TIME_ELAPSED=$(($END_TIME-$START_TIME))
372+ min=$((${TIME_ELAPSED}/60))
373+ sec=$((${TIME_ELAPSED}%60))
374+ TIME_ELAPSED="${min} min $sec seconds "
375+ echo "TIME_ELAPSED=${TIME_ELAPSED}" >> $GITHUB_ENV
376+ - name : Generate HTML Report
377+ shell : bash
378+ run : |
379+ cd minikube_binaries
380+ export PATH=${PATH}:`go env GOPATH`/bin
381+ go tool test2json -t < ./report/testout.txt > ./report/testout.json || true
382+ STAT=$(gopogh -in ./report/testout.json -out_html ./report/testout.html -out_summary ./report/testout_summary.json -name "${JOB_NAME} ${GITHUB_REF}" -repo "${GITHUB_REPOSITORY}" -details "${GITHUB_SHA}") || true
383+ echo status: ${STAT}
384+ FailNum=$(echo $STAT | jq '.NumberOfFail')
385+ TestsNum=$(echo $STAT | jq '.NumberOfTests')
386+ GOPOGH_RESULT="${JOB_NAME} : completed with ${FailNum} / ${TestsNum} failures in ${TIME_ELAPSED}"
387+ echo "GOPOGH_RESULT=${GOPOGH_RESULT}" >> $GITHUB_ENV
388+ echo 'STAT<<EOF' >> $GITHUB_ENV
389+ echo "${STAT}" >> $GITHUB_ENV
390+ echo 'EOF' >> $GITHUB_ENV
391+ - uses : actions/upload-artifact@83fd05a356d7e2593de66fc9913b3002723633cb
392+ with :
393+ name : functional_docker_rootless_containerd_ubuntu
394+ path : minikube_binaries/report
395+ - name : The End Result functional_docker_rootless_containerd_ubuntu
396+ shell : bash
397+ run : |
398+ echo ${GOPOGH_RESULT}
399+ numFail=$(echo $STAT | jq '.NumberOfFail')
400+ numPass=$(echo $STAT | jq '.NumberOfPass')
401+ echo "*******************${numPass} Passes :) *******************"
402+ echo $STAT | jq '.PassedTests' || true
403+ echo "*******************************************************"
404+ echo "---------------- ${numFail} Failures :( ----------------------------"
405+ echo $STAT | jq '.FailedTests' || true
406+ echo "-------------------------------------------------------"
407+ if [ "$numFail" -gt 0 ];then echo "*** $numFail Failed ***";exit 2;fi
408+ if [ "$numPass" -eq 0 ];then echo "*** 0 Passed! ***";exit 2;fi
409+ if [ "$numPass" -lt 36 ];then echo "*** Failed to pass at least 36 ! ***";exit 2;fi
410+ if [ "$numPass" -eq 0 ];then echo "*** Passed! ***";exit 0;fi
411+
293412 functional_podman_ubuntu :
294413 permissions :
295414 contents : none
@@ -611,6 +730,7 @@ jobs:
611730 [
612731 functional_docker_ubuntu,
613732 functional_docker_containerd_ubuntu,
733+ functional_docker_rootless_containerd_ubuntu,
614734 functional_podman_ubuntu,
615735 functional_virtualbox_macos,
616736 functional_baremetal_ubuntu20_04,
@@ -627,6 +747,7 @@ jobs:
627747 ls -lah
628748 cp -r ./functional_docker_ubuntu ./all_reports/
629749 cp -r ./functional_docker_containerd_ubuntu ./all_reports/
750+ cp -r ./functional_docker_rootless_containerd_ubuntu ./all_reports/
630751 cp -r ./functional_podman_ubuntu ./all_reports/
631752 cp -r ./functional_virtualbox_macos ./all_reports/
632753 cp -r ./functional_baremetal_ubuntu20_04 ./all_reports/
0 commit comments