From d7c413575be9e9af56589b4cebb52fc516f51cd7 Mon Sep 17 00:00:00 2001 From: Felix Matouschek Date: Fri, 20 Sep 2024 15:32:21 +0200 Subject: [PATCH] cleanup: Remove remains of early functest implementation Remove the no longer used functest and virtctl commands from scripts/kubevirt.sh and scripts/kubevirtci.sh. Signed-off-by: Felix Matouschek --- scripts/kubevirt.sh | 13 +------------ scripts/kubevirtci.sh | 20 +------------------- 2 files changed, 2 insertions(+), 31 deletions(-) diff --git a/scripts/kubevirt.sh b/scripts/kubevirt.sh index 182528a1..07e44baf 100755 --- a/scripts/kubevirt.sh +++ b/scripts/kubevirt.sh @@ -26,7 +26,6 @@ _base_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd) _kubectl="${_base_dir}/_kubevirt/cluster-up/kubectl.sh" _kubessh="${_base_dir}/_kubevirt/cluster-up/ssh.sh" _kubevirtcicli="${_base_dir}/_kubevirt/cluster-up/cli.sh" -_virtctl="${_base_dir}/_kubevirt/cluster-up/virtctl.sh" _action=$1 shift @@ -67,10 +66,6 @@ function kubevirt::registry() { echo "localhost:${port}" } -function kubevirt::functest() { - KUBECTL=${_kubectl} VIRTCTL=${_virtctl} "${_base_dir}/scripts/functest.sh" -} - kubevirt::install cd "${_base_dir}"/_kubevirt @@ -94,20 +89,14 @@ case ${_action} in "registry") kubevirt::registry ;; - "functest") - kubevirt::functest - ;; "ssh") ${_kubessh} "$@" ;; "kubectl") ${_kubectl} "$@" ;; - "virtctl") - ${_virtctl} "$@" - ;; *) - echo "No command provided, known commands are 'up', 'down', 'sync', 'ssh', 'kubeconfig', 'registry', 'kubectl', 'functest'" + echo "No command provided, known commands are 'up', 'down', 'sync', 'ssh', 'kubeconfig', 'registry', 'kubectl'" exit 1 ;; esac diff --git a/scripts/kubevirtci.sh b/scripts/kubevirtci.sh index 280aa176..e9e72046 100755 --- a/scripts/kubevirtci.sh +++ b/scripts/kubevirtci.sh @@ -26,11 +26,9 @@ export KUBEVIRT_VERSION=${KUBEVIRT_VERSION:-main)} _base_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd) _cluster_up_dir="${_base_dir}/_cluster-up" -_virtctl_dir="${_cluster_up_dir}/_out/cmd/virtctl" _kubectl="${_cluster_up_dir}/cluster-up/kubectl.sh" _kubessh="${_cluster_up_dir}/cluster-up/ssh.sh" _kubevirtcicli="${_cluster_up_dir}/cluster-up/cli.sh" -_virtctl="${_cluster_up_dir}/cluster-up/virtctl.sh" _action=$1 shift @@ -57,12 +55,6 @@ function kubevirtci::up() { ${_kubectl} apply -f "https://github.com/kubevirt/kubevirt/releases/download/${KUBEVIRT_VERSION}/kubevirt-operator.yaml" ${_kubectl} apply -f "https://github.com/kubevirt/kubevirt/releases/download/${KUBEVIRT_VERSION}/kubevirt-cr.yaml" - # This is needed because kubevirtci does not provide its own virtctl binary - echo "installing virtctl..." - mkdir -p "${_virtctl_dir}" - curl -L "https://github.com/kubevirt/kubevirt/releases/download/${KUBEVIRT_VERSION}/virtctl-${KUBEVIRT_VERSION}-linux-amd64" -o "${_virtctl_dir}/virtctl" - chmod +x "${_virtctl_dir}/virtctl" - echo "waiting for kubevirt to become ready, this can take a few minutes..." ${_kubectl} -n kubevirt wait kv kubevirt --for condition=Available --timeout=15m @@ -94,10 +86,6 @@ function kubevirtci::registry() { echo "localhost:${port}" } -function kubevirtci::functest() { - KUBECTL=${_kubectl} VIRTCTL=${_virtctl} "${_base_dir}/scripts/functest.sh" -} - kubevirtci::fetch_kubevirtci case ${_action} in @@ -119,20 +107,14 @@ case ${_action} in "registry") kubevirtci::registry ;; - "functest") - kubevirtci::functest - ;; "ssh") ${_kubessh} "$@" ;; "kubectl") ${_kubectl} "$@" ;; - "virtctl") - ${_virtctl} "$@" - ;; *) - echo "No command provided, known commands are 'up', 'down', 'sync', 'ssh', 'kubeconfig', 'registry', 'kubectl', 'functest'" + echo "No command provided, known commands are 'up', 'down', 'sync', 'ssh', 'kubeconfig', 'registry', 'kubectl'" exit 1 ;; esac