Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #862 from annastopel/cdi-okd-ci
OLM - ci -test. Create cdi-olm-catalog to be able to deploy cdi via o…
- Loading branch information
Showing
86 changed files
with
12,548 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
CDI_INISTALL=${CDI_INSTALL_OPERATOR} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -e | ||
source ./cluster-sync/${KUBEVIRT_PROVIDER}/install.sh | ||
|
||
function install_cdi_olm { | ||
#Install CDI via OLM | ||
_kubectl create ns $NAMESPACE | ||
_kubectl apply -f _out/manifests/release/olm/operatorgroup.yaml | ||
_kubectl apply -f _out/manifests/release/olm/k8s/cdi-catalogsource-registry.yaml | ||
_kubectl apply -f _out/manifests/release/olm/k8s/cdi-subscription.yaml | ||
} | ||
|
||
function install_cdi_operator { | ||
_kubectl apply -f "./_out/manifests/release/cdi-operator.yaml" | ||
} | ||
|
||
|
||
function install_cdi { | ||
case "${CDI_INSTALL}" in | ||
"${CDI_INSTALL_OPERATOR}") | ||
install_cdi_operator | ||
;; | ||
"${CDI_INSTALL_OLM}") | ||
install_cdi_olm | ||
;; | ||
esac | ||
} | ||
|
||
|
||
function wait_cdi_crd_installed { | ||
timeout=$1 | ||
crd_defined=0 | ||
while [ $crd_defined -eq 0 ] && [ $timeout > 0 ]; do | ||
crd_defined=$(_kubectl get customresourcedefinition| grep cdis.cdi.kubevirt.io | wc -l) | ||
sleep 1 | ||
timeout=timeout-1 | ||
done | ||
|
||
#In case CDI crd is not defined after 120s - throw error | ||
if [ $timeout \< 1 ]; then | ||
echo "ERROR - CDI CRD is not defined after timeout" | ||
exit 1 | ||
fi | ||
|
||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
CDI_INSTALL=${CDI_INSTALL_OPERATOR} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,3 +9,5 @@ re='^-?[0-9]+$' | |
if ! [[ $num_nodes =~ $re ]] || [[ $num_nodes -lt 1 ]] ; then | ||
num_nodes=1 | ||
fi | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
CDI_INSTALL=${CDI_INSTALL_OLM} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,3 +47,4 @@ function configure_local_storage() { | |
set -e | ||
fi | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
CDI_INSTALL=${CDI_INSTALL_OPERATOR} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,3 +9,6 @@ re='^-?[0-9]+$' | |
if ! [[ $num_nodes =~ $re ]] || [[ $num_nodes -lt 1 ]] ; then | ||
num_nodes=1 | ||
fi | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.