Skip to content

Commit 688d4f3

Browse files
Merge pull request #1077 from ASBishop/lvms-namespace
LVMS: Update default lvms-operator namespace
2 parents 00d5b2b + 8bf5680 commit 688d4f3

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

scripts/gen-lvms-kustomize.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ REQUIRE_RESTART=${REQUIRE_RESTART:-1}
1313
# if this parameter is set to 1, a LVM_CLUSTER CR is created and applied,
1414
# otherwise, only the operator is deployed through OLM
1515
LVMS_CLUSTER_CR=${LVMS_CLUSTER_CR:-0}
16-
LVMS_NAMESPACE=${LVMS_NAMESPACE:-openshift-storage}
16+
LVMS_NAMESPACE=${LVMS_NAMESPACE:-openshift-lvm-storage}
1717

1818
# Timeout defaults
1919
API_TIMEOUT=100
@@ -123,13 +123,13 @@ oc apply -f "${DEPLOY_DIR}"/lvms_cluster.yaml
123123
}
124124

125125

126-
# Patch openshift-storage namespace to get the right annotations
126+
# Patch the LVMS namespace to get the right annotations
127127
function patch_lvms_ns {
128128
cat <<EOF >lvms_ns.yaml
129129
apiVersion: v1
130130
kind: Namespace
131131
metadata:
132-
name: openshift-storage
132+
name: $LVMS_NAMESPACE
133133
annotations:
134134
workload.openshift.io/allowed: "management"
135135
openshift.io/sa.scc.uid-range: "1000090000/10000"
@@ -149,7 +149,7 @@ function get_csv_version {
149149
(( CSV_TIMEOUT-- ))
150150
[[ "$CSV_TIMEOUT" -eq 0 ]] && exit 1
151151
done
152-
oc -n openshift-storage get csv -o json | jq -r '.items[] | select(.metadata.name | contains("lvms-operator")) | .spec.version'
152+
oc -n $LVMS_NAMESPACE get csv -o json | jq -r '.items[] | select(.metadata.name | contains("lvms-operator")) | .spec.version'
153153
}
154154

155155
function patch_csv_metrics {
@@ -199,7 +199,7 @@ function main {
199199
else
200200
# Deploy LVMS operator
201201
lvms_operator_deploy
202-
# Patch the openshift-storage namespace with the
202+
# Patch the LVMS namespace with the
203203
# expected annotations and labels.
204204
echo "Rolling out the lvms-operator"
205205
patch_lvms_ns

0 commit comments

Comments
 (0)