fix(e2e-setup.sh): Wait for CDI to be available

Wait for CDI to be available after deploying it.

Also add the missing --deploy-kubevirt-cdi flag to the usage help.

Signed-off-by: Felix Matouschek <fmatouschek@redhat.com>
This commit is contained in:
Felix Matouschek
2025-05-09 10:19:58 +02:00
parent 9ac287f57e
commit 6570b7fc7e

View File

@@ -239,6 +239,12 @@ deploy_kubevirt_containerized_data_importer() {
echo "Deploying KubeVirt containerized-data-importer" echo "Deploying KubeVirt containerized-data-importer"
${KUBECTL} apply -f "https://github.com/kubevirt/containerized-data-importer/releases/download/${KUBEVIRT_CDI_VERSION}/cdi-operator.yaml" ${KUBECTL} apply -f "https://github.com/kubevirt/containerized-data-importer/releases/download/${KUBEVIRT_CDI_VERSION}/cdi-operator.yaml"
${KUBECTL} apply -f "https://github.com/kubevirt/containerized-data-importer/releases/download/${KUBEVIRT_CDI_VERSION}/cdi-cr.yaml" ${KUBECTL} apply -f "https://github.com/kubevirt/containerized-data-importer/releases/download/${KUBEVIRT_CDI_VERSION}/cdi-cr.yaml"
echo "Waiting for KubeVirt containerized-data-importer to be ready"
${KUBECTL} wait --for=condition=Available cdi cdi --timeout=5m
echo "Successfully deployed KubeVirt containerized-data-importer:"
${KUBECTL} get pods -n cdi
} }
deploy_cnao() { deploy_cnao() {
@@ -307,7 +313,7 @@ cleanup() {
} }
usage() { usage() {
echo -n "$0 [--install-kind] [--install-kubectl] [--configure-inotify-limits] [--create-registry] [--create-cluster] [--deploy-kubevirt] [--deploy-cnao] [--create-nad] [--cleanup] [--namespace]" echo -n "$0 [--install-kind] [--install-kubectl] [--configure-inotify-limits] [--create-registry] [--create-cluster] [--deploy-kubevirt] [--deploy-kubevirt-cdi] [--deploy-cnao] [--create-nad] [--cleanup] [--namespace]"
} }
set_default_options() { set_default_options() {