From 6b71d43b5cc7426ee626a9ff7ac1421dbd64f2e7 Mon Sep 17 00:00:00 2001 From: Vishal Thapar <5137689+vthapar@users.noreply.github.com> Date: Wed, 13 Jan 2021 15:22:04 +0530 Subject: [PATCH 1/3] Enable OVN CNI * Enable OVN in Makefile * Add OVN jobs to e2e Signed-off-by: Vishal Thapar <5137689+vthapar@users.noreply.github.com> --- .github/workflows/e2e.yml | 9 ++++++++- Makefile | 6 ++++++ scripts/cluster_settings.ovn | 6 ++++++ 3 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 scripts/cluster_settings.ovn diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 00ab57365..ff4fbb4d1 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -15,12 +15,19 @@ jobs: deploytool: ['operator', 'helm'] globalnet: ['', 'globalnet'] cable_driver: ['libreswan', 'strongswan', 'wireguard'] + ovn: ['', 'ovn'] exclude: # Our Helm setup doesn’t know how to deploy other cable drivers - deploytool: 'helm' cable_driver: 'wireguard' - deploytool: 'helm' cable_driver: 'libreswan' + - ovn: 'ovn' + deploytool: 'helm' + - ovn: 'ovn' + globalnet: 'globalnet' + - ovn: 'ovn' + cable_driver: 'strongswan' steps: - name: Check out the repository uses: actions/checkout@v2 @@ -40,7 +47,7 @@ jobs: - name: Run E2E deployment and tests run: | - make e2e using="${{ matrix.globalnet }} ${{ matrix.deploytool }} ${{ matrix.cable_driver }}" + make e2e using="${{ matrix.globalnet }} ${{ matrix.deploytool }} ${{ matrix.cable_driver }} ${{ matrix.ovn }}" - name: Post mortem if: failure() diff --git a/Makefile b/Makefile index 0d35c227f..a8520e2cc 100644 --- a/Makefile +++ b/Makefile @@ -9,7 +9,13 @@ include $(SHIPYARD_DIR)/Makefile.inc TARGETS := $(shell ls -p scripts | grep -v -e / -e reload-images) override BUILD_ARGS += $(shell source ${SCRIPTS_DIR}/lib/version; echo --ldflags \'-X main.VERSION=$${VERSION}\') + +ifneq (,$(filter ovn,$(_using))) +override CLUSTERS_ARGS += --cluster_settings $(DAPPER_SOURCE)/scripts/cluster_settings.ovn +else override CLUSTERS_ARGS += --cluster_settings $(DAPPER_SOURCE)/scripts/cluster_settings +endif + override E2E_ARGS += --focus $(focus) cluster2 cluster3 cluster1 override UNIT_TEST_ARGS += test/e2e override VALIDATE_ARGS += --skip-dirs pkg/client diff --git a/scripts/cluster_settings.ovn b/scripts/cluster_settings.ovn new file mode 100644 index 000000000..2bcb33ba1 --- /dev/null +++ b/scripts/cluster_settings.ovn @@ -0,0 +1,6 @@ +# Specific settings for the submariner E2E +cluster_nodes['cluster1']="control-plane worker" +cluster_nodes['cluster2']="control-plane worker worker" +cluster_nodes['cluster3']="control-plane worker worker" + +cluster_cni=( ['cluster1']="ovn" ['cluster2']="ovn" ['cluster3']="ovn" ) From 276d7145329ad251a8822ab6385ae4e517cd158d Mon Sep 17 00:00:00 2001 From: Miguel Angel Ajo Date: Mon, 25 Jan 2021 09:51:32 +0100 Subject: [PATCH 2/3] Cleanup additional space and stop removing swap There are 30GB+ of files in tools that we don't need or use for building submariner, we mostly work inside of docker. Those files are removed now. Swap isn't disabled anymore, now GitHub uses a separate disk for swap /dev/sdb instead of the main disk. Signed-off-by: Miguel Angel Ajo --- .github/workflows/e2e.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index ff4fbb4d1..ce2b2fdb1 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -40,8 +40,8 @@ jobs: - name: Reclaim free space run: | - sudo swapoff -a - sudo rm -f /swapfile + # cleanup 30GB+ of tools we don't need for our CI + rm -rf /opt/ghc /usr/share/dotnet /usr/share/swift df -h free -h From 3e204b066c694dba063190b8dba4d3baa1814dab Mon Sep 17 00:00:00 2001 From: Miguel Angel Ajo Pelayo Date: Tue, 26 Jan 2021 22:24:39 +0100 Subject: [PATCH 3/3] Apply suggestions from code review --- .github/workflows/e2e.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index ce2b2fdb1..56a60b13f 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -40,7 +40,7 @@ jobs: - name: Reclaim free space run: | - # cleanup 30GB+ of tools we don't need for our CI + # cleanup 30GB+ of tools we don't need for our CI ... bump rm -rf /opt/ghc /usr/share/dotnet /usr/share/swift df -h free -h