From 67449433c6e3127ed2a0ba04c9ebdeba14c8ae90 Mon Sep 17 00:00:00 2001 From: Anna McAllister Date: Tue, 14 Jan 2025 11:16:10 +0000 Subject: [PATCH] add option to gradle installOperator to set mode Signed-off-by: Anna McAllister --- operator/Makefile | 3 ++- operator/build.gradle | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/operator/Makefile b/operator/Makefile index c2ffb1f56..cd5f6241a 100644 --- a/operator/Makefile +++ b/operator/Makefile @@ -211,7 +211,8 @@ helm-install: helm-install-dependencies ## Install operator using Helm. --set paladin.image.repository=${PALADIN_IMAGE_NAME} \ --set paladin.image.tag=${PALADIN_IMAGE_TAG} \ --set paladin.image.pullPolicy=IfNotPresent \ - --set prometheus.enabled=false + --set prometheus.enabled=false \ + --set mode=${MODE} .PHONY: helm-uninstall-dependencies helm-uninstall-dependencies: diff --git a/operator/build.gradle b/operator/build.gradle index 8dc6c65de..b40d48012 100644 --- a/operator/build.gradle +++ b/operator/build.gradle @@ -52,7 +52,8 @@ dependencies { ext { clusterName = project.hasProperty('clusterName') ? project.clusterName : 'paladin' - namespace = project.hasProperty('namespace') ? project.namespace : 'default' // Default namespace is 'default' + namespace = project.hasProperty('namespace') ? project.namespace : 'default' // Default namespace is 'default' + mode = project.hasProperty('mode') ? project.mode : 'devnet' deleteCluster = project.hasProperty('deleteCluster') ? project.deleteCluster.toBoolean() : false // By default, do not delete the cluster buildPaladin = project.hasProperty('buildPaladin') ? project.buildPaladin == 'true' : true // Default is to build Paladin buildOperator = project.hasProperty('buildOperator') ? project.buildOperator == 'true' : true // Default is to build the operator @@ -233,6 +234,7 @@ task installOperator(type: Exec, dependsOn: [installCrds, promoteKindImages, pre args "OPERATOR_IMAGE_TAG=${operatorImageTag}" args "PALADIN_IMAGE_NAME=${paladinImageName}" args "PALADIN_IMAGE_TAG=${paladinImageTag}" + args "MODE=${mode}" }