Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cleanup.sh: wait for provier-networks to be deleted before deleting kube-ovn-cni #3006

Merged
merged 1 commit into from
Jul 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 9 additions & 12 deletions .github/workflows/build-x86-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -968,10 +968,7 @@ jobs:
done

- name: Cleanup
run: |
if [ "${{ matrix.mode }}" != underlay ]; then
sh -x dist/images/cleanup.sh
fi
run: sh -x dist/images/cleanup.sh

kube-ovn-ic-conformance-e2e:
name: Kube-OVN IC Conformance E2E
Expand Down Expand Up @@ -1108,7 +1105,7 @@ jobs:
run: make kind-install-chart

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

underlay-logical-gateway-installation-test:
name: Underlay Logical Gateway Installation Test
Expand Down Expand Up @@ -1144,7 +1141,7 @@ jobs:
run: make kind-install-underlay-logical-gateway-dual

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

no-ovn-lb-test:
name: Disable OVN LB Test
Expand Down Expand Up @@ -1182,7 +1179,7 @@ jobs:
run: make kind-install

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

no-np-test:
name: Disable Network Policy Test
Expand Down Expand Up @@ -1220,7 +1217,7 @@ jobs:
run: make kind-install

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

lb-svc-e2e:
name: LB Service E2E
Expand Down Expand Up @@ -1535,7 +1532,7 @@ jobs:
path: installation-compatibility-test-ko-log.tar.gz

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

cilium-chaining-e2e:
name: Cilium Chaining E2E
Expand Down Expand Up @@ -1642,7 +1639,7 @@ jobs:
path: cilium-chaining-e2e-ko-log.tar.gz

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

kube-ovn-security-e2e:
name: Kube-OVN Security E2E
Expand Down Expand Up @@ -1757,7 +1754,7 @@ jobs:
path: kube-ovn-security-e2e-${{ matrix.ssl }}-${{ matrix.bind-local }}-${{ matrix.ip-family }}-ko-log.tar.gz

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

push:
name: Push Images
Expand Down Expand Up @@ -1930,7 +1927,7 @@ jobs:
path: kube-ovn-submariner-conformance-e2e-ko-log.tar.gz

- name: Cleanup
run: sh dist/images/cleanup.sh
run: sh -x dist/images/cleanup.sh

iptables-vpc-nat-gw-conformance-e2e:
name: Iptables VPC NAT Gateway E2E
Expand Down
5 changes: 4 additions & 1 deletion dist/images/cleanup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,12 @@ done
kubectl delete --ignore-not-found deploy kube-ovn-monitor -n kube-system
kubectl delete --ignore-not-found cm ovn-config ovn-ic-config ovn-external-gw-config -n kube-system
kubectl delete --ignore-not-found svc kube-ovn-pinger kube-ovn-controller kube-ovn-cni kube-ovn-monitor -n kube-system
kubectl delete --ignore-not-found ds kube-ovn-cni -n kube-system
kubectl delete --ignore-not-found deploy kube-ovn-controller -n kube-system

# wait for provier-networks to be deleted before deleting kube-ovn-cni
sleep 5
kubectl delete --ignore-not-found ds kube-ovn-cni -n kube-system

# ensure kube-ovn-cni has been deleted
while :; do
if [ $(kubectl get pod --no-headers -n kube-system -l app=kube-ovn-cni | wc -l) -eq 0 ]; then
Expand Down