Skip to content

Commit 857049b

Browse files
Merge pull request #933 from pablintino/nmstate-parameters
Add NMstate OLM CR name parameters
2 parents 5081b74 + be56fbb commit 857049b

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

Makefile

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -432,6 +432,11 @@ CEPH_OP ?= ${OPERATOR_BASE_DIR}/rook/deploy/examples/operator-openshift.y
432432
CEPH_CR ?= ${OPERATOR_BASE_DIR}/rook/deploy/examples/cluster-test.yaml
433433
CEPH_CLIENT ?= ${OPERATOR_BASE_DIR}/rook/deploy/examples/toolbox.yaml
434434

435+
# NNstate
436+
NMSTATE_NAMESPACE ?= openshift-nmstate
437+
NMSTATE_OPERATOR_GROUP ?= openshift-nmstate-tn6k8
438+
NMSTATE_SUBSCRIPTION ?= kubernetes-nmstate-operator
439+
435440
# NNCP
436441
NNCP_NODES ?=
437442
NNCP_INTERFACE ?= enp6s0
@@ -2216,7 +2221,9 @@ lvms_deploy_cleanup: ## delete the lvms cluster
22162221

22172222
##@ NMSTATE
22182223
.PHONY: nmstate
2219-
nmstate: export NAMESPACE=openshift-nmstate
2224+
nmstate: export NAMESPACE=${NMSTATE_NAMESPACE}
2225+
nmstate: export OPERATOR_GROUP=${NMSTATE_OPERATOR_GROUP}
2226+
nmstate: export SUBSCRIPTION=${NMSTATE_SUBSCRIPTION}
22202227
nmstate: ## installs nmstate operator in the openshift-nmstate namespace
22212228
$(eval $(call vars,$@,nmstate))
22222229
bash scripts/gen-namespace.sh

scripts/gen-olm-nmstate.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ metadata:
4141
annotations:
4242
olm.providedAPIs: NMState.v1.nmstate.io
4343
generateName: openshift-nmstate-
44-
name: openshift-nmstate-tn6k8
44+
name: ${OPERATOR_GROUP}
4545
namespace: ${NAMESPACE}
4646
spec:
4747
targetNamespaces:
@@ -54,12 +54,12 @@ kind: Subscription
5454
metadata:
5555
labels:
5656
operators.coreos.com/kubernetes-nmstate-operator.openshift-nmstate: ""
57-
name: kubernetes-nmstate-operator
57+
name: ${SUBSCRIPTION}
5858
namespace: ${NAMESPACE}
5959
spec:
6060
channel: stable
6161
installPlanApproval: Automatic
62-
name: kubernetes-nmstate-operator
62+
name: ${SUBSCRIPTION}
6363
source: redhat-operators
6464
sourceNamespace: openshift-marketplace
6565
EOF_CAT

0 commit comments

Comments
 (0)