1- NAME ?= $(shell yq .global.pattern values-global.yaml)
1+ PATTERN_NAME ?= $(shell yq .global.pattern values-global.yaml)
22
3- ifeq ($(NAME ) ,)
3+ ifeq ($(PATTERN_NAME ) ,)
44$(error Pattern name MUST be set in values-global.yaml with the value .global.pattern)
55endif
6- ifeq ($(NAME ) ,null)
6+ ifeq ($(PATTERN_NAME ) ,null)
77$(error Pattern name MUST be set in values-global.yaml with the value .global.pattern)
88endif
99
@@ -83,14 +83,14 @@ PATTERN_INSTALL_CHART ?= oci://quay.io/hybridcloudpatterns/pattern-install
8383
8484.PHONY : help
8585help : # # This help message
86- @echo " Pattern: $( NAME ) "
86+ @echo " Pattern: $( PATTERN_NAME ) "
8787 @awk ' BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m<target>\033[0m\n"} /^(\s|[a-zA-Z_0-9-])+:.*?##/ { printf " \033[36m%-35s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST )
8888
8989# Makefiles in the individual patterns should call these targets explicitly
9090# e.g. from industrial-edge: make -f common/Makefile show
9191.PHONY : show
9292show : # # show the starting template without installing it
93- helm template $(PATTERN_INSTALL_CHART ) --name-template $(NAME ) $(HELM_OPTS )
93+ helm template $(PATTERN_INSTALL_CHART ) --name-template $(PATTERN_NAME ) $(HELM_OPTS )
9494
9595preview-all : # # (EXPERIMENTAL) Previews all applications on hub and managed clusters
9696 @echo " NOTE: This is just a tentative approximation of rendering all hub and managed clusters templates"
@@ -102,21 +102,21 @@ preview-%:
102102
103103.PHONY : operator-deploy
104104operator-deploy operator-upgrade : validate-prereq $(VALIDATE_ORIGIN ) validate-cluster # # runs helm install
105- @common/scripts/deploy-pattern.sh $(NAME ) $(PATTERN_INSTALL_CHART ) $(HELM_OPTS )
105+ @common/scripts/deploy-pattern.sh $(PATTERN_NAME ) $(PATTERN_INSTALL_CHART ) $(HELM_OPTS )
106106
107107.PHONY : uninstall
108108uninstall : # # runs helm uninstall
109109 $(eval CSV := $(shell oc get subscriptions -n openshift-operators openshift-gitops-operator -ojsonpath={.status.currentCSV}) )
110- helm uninstall $(NAME )
110+ helm uninstall $(PATTERN_NAME )
111111 @oc delete csv -n openshift-operators $(CSV )
112112
113113.PHONY : load-secrets
114114load-secrets : # # loads the secrets into the backend determined by values-global setting
115- common/scripts/process-secrets.sh $(NAME )
115+ common/scripts/process-secrets.sh $(PATTERN_NAME )
116116
117117.PHONY : legacy-load-secrets
118118legacy-load-secrets : # # loads the secrets into vault (only)
119- common/scripts/vault-utils.sh push_secrets $(NAME )
119+ common/scripts/vault-utils.sh push_secrets $(PATTERN_NAME )
120120
121121.PHONY : secrets-backend-vault
122122secrets-backend-vault : # # Edits values files to use default Vault+ESO secrets config
0 commit comments