From 322294d8066878ae684e0af668c447331506d031 Mon Sep 17 00:00:00 2001 From: craig Date: Mon, 2 Oct 2023 13:53:48 +0100 Subject: [PATCH] make service protection an option --- hack/.deployUtils | 5 ++++- hack/quickstart-setup.sh | 9 ++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/hack/.deployUtils b/hack/.deployUtils index 22c47c303..98f27fdba 100644 --- a/hack/.deployUtils +++ b/hack/.deployUtils @@ -64,7 +64,10 @@ deployOCMHub(){ echo "checking if cluster is single or multi" if [[ -n "${OCM_SINGLE}" ]]; then deployOCMSpoke ${clusterName} - configureManagedAddon ${clusterName} ${clusterName} + if [ "${MGC_DEPLOY_SERVICE_PROTECTION}" = true ]; then + echo "deploying kuadrant service protection to ${clusterName}" + configureManagedAddon ${clusterName} ${clusterName} + fi deployOLM ${KIND_CLUSTER_CONTROL_PLANE} if ! [[ -n "${minimal}" ]]; then diff --git a/hack/quickstart-setup.sh b/hack/quickstart-setup.sh index a50fde732..1002011be 100755 --- a/hack/quickstart-setup.sh +++ b/hack/quickstart-setup.sh @@ -76,6 +76,10 @@ fi if [[ -z "${MGC_WORKLOAD_CLUSTERS_COUNT}" ]]; then MGC_WORKLOAD_CLUSTERS_COUNT=1 fi +if [[ -z "${MGC_DEPLOY_SERVICE_PROTECTION}"]]; then + MGC_DEPLOY_SERVICE_PROTECTION=true +fi + # Make temporary directory for kubeconfig mkdir -p ${TMP_DIR} @@ -103,7 +107,10 @@ if [[ -n "${MGC_WORKLOAD_CLUSTERS_COUNT}" ]]; then configureMetalLB ${KIND_CLUSTER_WORKLOAD}-${i} $((${metalLBSubnetStart} + ${i})) deployOLM ${KIND_CLUSTER_WORKLOAD}-${i} deployOCMSpoke ${KIND_CLUSTER_WORKLOAD}-${i} - configureManagedAddon ${KIND_CLUSTER_CONTROL_PLANE} ${KIND_CLUSTER_WORKLOAD}-${i} + if [ "${MGC_DEPLOY_SERVICE_PROTECTION}" = true ]; then + echo "deploying kuadrant service protection" + configureManagedAddon ${KIND_CLUSTER_CONTROL_PLANE} ${KIND_CLUSTER_WORKLOAD}-${i} + fi done fi