From 5bdf9c56d8b6296492baae9c85262cf12ecd91a7 Mon Sep 17 00:00:00 2001 From: Michael Barroco Date: Fri, 26 Jan 2024 10:39:25 +0100 Subject: [PATCH] [ci] Wait for helm before next steps --- .../terraform-aws-kubernetes/network_lb.tf | 2 ++ deploy/operations/ci/aws-1/test.sh | 12 +++++++----- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/deploy/infrastructure/dependencies/terraform-aws-kubernetes/network_lb.tf b/deploy/infrastructure/dependencies/terraform-aws-kubernetes/network_lb.tf index 5e13c698d..0c8df4b7e 100644 --- a/deploy/infrastructure/dependencies/terraform-aws-kubernetes/network_lb.tf +++ b/deploy/infrastructure/dependencies/terraform-aws-kubernetes/network_lb.tf @@ -7,6 +7,8 @@ resource "helm_release" "aws-load-balancer-controller" { namespace = "kube-system" + wait = true + set { name = "clusterName" value = var.cluster_name diff --git a/deploy/operations/ci/aws-1/test.sh b/deploy/operations/ci/aws-1/test.sh index 413149e69..a59d833c1 100755 --- a/deploy/operations/ci/aws-1/test.sh +++ b/deploy/operations/ci/aws-1/test.sh @@ -37,7 +37,8 @@ kubectl apply -f "aws_auth_config_map.yml" cd "$BASEDIR/../../../services/helm-charts/dss" RELEASE_NAME="dss" helm dep update --kube-context="$KUBE_CONTEXT" -helm upgrade --install --kube-context="$KUBE_CONTEXT" -f "${WORKSPACE_LOCATION}/helm_values.yml" "$RELEASE_NAME" . +helm upgrade --install --debug --kube-context="$KUBE_CONTEXT" -f "${WORKSPACE_LOCATION}/helm_values.yml" "$RELEASE_NAME" . +kubectl wait --for=condition=complete --timeout=3m job/rid-schema-manager-1 # TODO: Test the deployment of the DSS @@ -48,11 +49,12 @@ fi # Cleanup # Delete workloads -helm uninstall --kube-context="$KUBE_CONTEXT" "$RELEASE_NAME" +helm uninstall --debug --kube-context="$KUBE_CONTEXT" --wait --timeout 5m "$RELEASE_NAME" -# Delete PVC to delete persistant volumes -kubectl delete pvc --all=true -# TODO: Check completness +# Delete PVC to delete persistent volumes +kubectl delete pvc --wait --all=true +kubectl delete pv --wait --all=true +# TODO: Check completeness # Delete cluster cd "$BASEDIR"