tests: Adjust vmware.sh for GitLab CI

This commit is contained in:
Alexander Todorov 2021-05-27 11:45:27 +03:00 committed by Ondřej Budai
parent 3f823be4b1
commit 1927abea46

View file

@ -10,13 +10,23 @@ function greenprint {
echo -e "\033[1;32m${1}\033[0m"
}
if [ "$ID" != "rhel" ]; then
greenprint "VMware test not supported on $ID"
exit 0
fi
# Provision the software under tet.
/usr/libexec/osbuild-composer-test/provision.sh
GOVC_CMD=/tmp/govc
# Note: in GitLab CI the GOVMOMI_ variables are defined one-by-one
# instead of sourcing them from a file!
VCENTER_CREDS="${VCENTER_CREDS:-}"
if [ -n "$VCENTER_CREDS" ]; then
# shellcheck source=/dev/null
source "$VCENTER_CREDS"
source "$VCENTER_CREDS"
fi
# We need govc to talk to vSphere
if ! hash govc; then