From 61a726fd7d446b7e23a327f38c94168760bcec47 Mon Sep 17 00:00:00 2001 From: Brian Carey Date: Wed, 16 Oct 2024 14:41:57 +0100 Subject: [PATCH] gocli: Add wait for cri-o service to be ready after proxy settings applied There was previously a wait for the cri-o service to be ready[1] after applying the docker proxy settings but this was not included with the introduction of the opts package[2]. This can lead to kubeadm failing its preflight checks as cri-o is not ready[3] [1] https://github.com/kubevirt/kubevirtci/blob/03aa94e9da974b0e37dc8f180a4f700d47020c08/cluster-provision/k8s/1.31/nodes.sh#L43 [2] https://github.com/kubevirt/kubevirtci/pull/1217 [3] https://prow.ci.kubevirt.io/view/gs/kubevirt-prow/pr-logs/pull/kubevirt_kubevirt/13020/pull-kubevirt-e2e-k8s-1.31-sig-network/1843292337933914112#1:build-log.txt%3A343 Signed-off-by: Brian Carey --- cluster-provision/gocli/cmd/run.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cluster-provision/gocli/cmd/run.go b/cluster-provision/gocli/cmd/run.go index 7b512a7cc1..c9bc79177c 100644 --- a/cluster-provision/gocli/cmd/run.go +++ b/cluster-provision/gocli/cmd/run.go @@ -68,6 +68,11 @@ EOT systemctl daemon-reload systemctl restart crio.service + +while [[ systemctl status crio | grep active | wc -l -eq 0 ]] +do + sleep 2 +done EOF ` etcdDataDir = "/var/lib/etcd"