From d55c56b8489538cb46674ca739891d9b10870a0c Mon Sep 17 00:00:00 2001 From: Shuyang Xin Date: Sun, 21 Jul 2024 22:27:23 +0800 Subject: [PATCH] [NOTFORREVIEW] Windows Build Test Signed-off-by: Shuyang Xin --- ci/jenkins/test.sh | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/ci/jenkins/test.sh b/ci/jenkins/test.sh index 690196b7270..cfc13869695 100755 --- a/ci/jenkins/test.sh +++ b/ci/jenkins/test.sh @@ -243,9 +243,10 @@ function collect_windows_network_info_and_logs { ANTREA_AGENT_LOG_PATH="${DEBUG_LOG_PATH}/${AGENTNAME}/antrea_agent_log" mkdir "${ANTREA_AGENT_LOG_PATH}" kubectl logs "${AGENTNAME}" -n kube-system -c antrea-agent > "${ANTREA_AGENT_LOG_PATH}/antrea-agent.log" - if [[ "${AGENTNAME}" =~ "windows" ]]; then + if [[ "${TESTCASE}" == "windows-e2e-ovs-as-service" ]]; then echo "Windows agent doesn't have antrea-ovs container" else + echo "=== Collecting '${AGENTNAME}' ovs log after failure ===" kubectl logs "${AGENTNAME}" -n kube-system -c antrea-ovs > "${ANTREA_AGENT_LOG_PATH}/antrea-ovs.log" fi done @@ -402,6 +403,8 @@ function build_and_deliver_antrea_windows_and_linux_images { ${PRINT_DOCKER_STATUS} export_govc_env_var # Enable verbose log for troubleshooting. + curl -OL http://build-squid.vcfd.broadcom.net/build/mts/release/sb-81093377/publish/windows-advanced/manifests/${WINDOWS_YAML_NAME}.yml + cp ${WINDOWS_YAML_NAME}.yml build/yamls/${WINDOWS_YAML_NAME}.yml sed -i "s/--v=0/--v=4/g" build/yamls/antrea.yml build/yamls/${WINDOWS_YAML_NAME}.yml echo "====== Updating yaml files to enable proxyAll ======" @@ -472,12 +475,8 @@ function deliver_antrea_linux { function deliver_antrea_windows { echo "===== Build Antrea Windows =====" rm -f antrea-windows.tar.gz - make build-windows - if ! (test -f antrea-windows.tar); then - echo "antrea-windows.tar wasn't built, exiting" - exit 1 - fi - gzip -f antrea-windows.tar + curl -OL http://build-squid.vcfd.broadcom.net/build/mts/release/sb-81093377/publish/windows-advanced/images/antrea-advanced-windows-v2.1.0_vmware.3.tar.gz + mv antrea-advanced-windows-v2.1.0_vmware.3.tar.gz antrea-windows.tar.gz echo "===== Deliver Antrea Windows to Windows worker nodes and pull necessary images on Windows worker nodes =====" sed -i 's/if (!(Test-Path $AntreaAgentConfigPath))/if ($true)/' hack/windows/Helper.psm1 @@ -770,9 +769,9 @@ function run_conformance_windows { export KUBE_TEST_REPO_LIST=${WORKDIR}/repo_list if [ "$TESTCASE" == "windows-networkpolicy" ]; then # Allow LinuxOnly mark in windows-networkpolicy because Antrea Windows supports NP functions. - ginkgo -timeout=3h -p --flake-attempts 3 --no-color $E2ETEST_PATH -- --provider=skeleton --ginkgo.focus="$WINDOWS_NETWORKPOLICY_FOCUS" --ginkgo.skip="$WINDOWS_NETWORKPOLICY_CONTAINERD_SKIP" > windows_conformance_result_no_color.txt || true + ginkgo -timeout=4h -p --flake-attempts 5 --no-color $E2ETEST_PATH -- --provider=skeleton --ginkgo.focus="$WINDOWS_NETWORKPOLICY_FOCUS" --ginkgo.skip="$WINDOWS_NETWORKPOLICY_CONTAINERD_SKIP" > windows_conformance_result_no_color.txt || true else - ginkgo --no-color $E2ETEST_PATH -- --provider=skeleton --node-os-distro=windows --ginkgo.focus="$WINDOWS_CONFORMANCE_FOCUS" --ginkgo.skip="$WINDOWS_CONFORMANCE_SKIP" > windows_conformance_result_no_color.txt || true + ginkgo --flake-attempts 3 --no-color $E2ETEST_PATH -- --provider=skeleton --node-os-distro=windows --ginkgo.focus="$WINDOWS_CONFORMANCE_FOCUS" --ginkgo.skip="$WINDOWS_CONFORMANCE_SKIP" > windows_conformance_result_no_color.txt || true fi if grep -Fxq "Test Suite Failed" windows_conformance_result_no_color.txt; then @@ -1019,9 +1018,9 @@ fi trap clean_antrea EXIT if [[ ${TESTCASE} =~ "windows" ]]; then if [[ ${TESTCASE} == "windows-e2e-ovs-as-service" ]]; then - WINDOWS_YAML_NAME="antrea-windows" + WINDOWS_YAML_NAME="antrea-windows-v2.1.0+vmware.3" else - WINDOWS_YAML_NAME="antrea-windows-with-ovs" + WINDOWS_YAML_NAME="antrea-windows-v2.1.0+vmware.3" fi build_and_deliver_antrea_windows_and_linux_images if [[ ${TESTCASE} =~ "e2e" ]]; then