From 7034968d967ceae1dc46f5ad09238b6d720641c3 Mon Sep 17 00:00:00 2001 From: Gage Hugo Date: Thu, 30 Sep 2021 16:40:04 -0500 Subject: [PATCH] Move check jobs to use helm3 This change migrates the check jobs in OSH to use the new helm v3 script when deploying kubernetes via minikube. This is one step in the move to helm v3. Future changes will migrate the other jobs. Change-Id: If741db5997a27ed06584b9af2d50485d8de34a2b --- tools/deployment/common/run-helm-tests.sh | 2 +- tools/deployment/component/cinder/cinder.sh | 6 +++++- tools/deployment/component/glance/glance.sh | 2 ++ tools/deployment/component/horizon/horizon.sh | 5 ++++- tools/gate/deploy-k8s.sh | 21 +++++++++++++++++++ tools/scripts/tls/cert-manager.sh | 15 ++++--------- zuul.d/jobs-openstack-helm.yaml | 11 +++++----- 7 files changed, 42 insertions(+), 20 deletions(-) create mode 100755 tools/gate/deploy-k8s.sh diff --git a/tools/deployment/common/run-helm-tests.sh b/tools/deployment/common/run-helm-tests.sh index 17fd52990a..27e7db2d1c 100755 --- a/tools/deployment/common/run-helm-tests.sh +++ b/tools/deployment/common/run-helm-tests.sh @@ -10,7 +10,7 @@ timeout=${OSH_TEST_TIMEOUT:-900} run_tests() { # Delete the test pod if it still exists kubectl delete pods -l application=${APPLICATION},release_group=${RELEASE_GROUP},component=test --namespace=${NAMESPACE} --ignore-not-found - helm test ${APPLICATION} --timeout $timeout + helm test ${APPLICATION} --timeout ${timeout}s --namespace=${NAMESPACE} } for i in $(seq 1 ${HELM_TESTS_TRIES}); do diff --git a/tools/deployment/component/cinder/cinder.sh b/tools/deployment/component/cinder/cinder.sh index 67fc1467db..457773b230 100755 --- a/tools/deployment/component/cinder/cinder.sh +++ b/tools/deployment/component/cinder/cinder.sh @@ -15,6 +15,7 @@ set -xe #NOTE: Get the over-rides to use : ${OSH_EXTRA_HELM_ARGS_CINDER:="$(./tools/deployment/common/get-values-overrides.sh cinder)"} +: ${RUN_HELM_TESTS:="yes"} #NOTE: Lint and package chart make cinder @@ -75,4 +76,7 @@ openstack volume type list --default # Delete the test pod if it still exists kubectl delete pods -l application=cinder,release_group=cinder,component=test --namespace=openstack --ignore-not-found -helm test cinder --timeout 900 + +if [ "x${RUN_HELM_TESTS}" != "xno" ]; then + ./tools/deployment/common/run-helm-tests.sh cinder +fi diff --git a/tools/deployment/component/glance/glance.sh b/tools/deployment/component/glance/glance.sh index 31a32ea2d8..feb237a6a7 100755 --- a/tools/deployment/component/glance/glance.sh +++ b/tools/deployment/component/glance/glance.sh @@ -27,6 +27,8 @@ make glance : ${GLANCE_BACKEND:="pvc"} tee /tmp/glance.yaml <