1
0
mirror of https://github.com/kata-containers/kata-containers.git synced 2025-09-11 13:49:16 +00:00

tests: k8s: Clean up node debuggers after running

This deletes node debugger pods after execution since their presence may
affect tests that assume only test workloads pods are present.

For example, in `k8s-job` we wait for *any* pod to be in the `Succeeded`
state before proceeding, which causes failures.

Fixes: 

Signed-off-by: Aurélien Bombo <abombo@microsoft.com>
This commit is contained in:
Aurélien Bombo
2023-07-25 15:22:57 -07:00
parent 5385ddc560
commit 6daeb08e69

@@ -175,6 +175,7 @@ function get_nodes_and_pods_info() {
echo "::endgroup::"
fi
kubectl debug $(kubectl get nodes -o name) -it --image=quay.io/kata-containers/kata-debug:latest
kubectl get pods -o name | grep node-debugger | xargs kubectl delete
}
function main() {