Skip to content

Commit

Permalink
update nss resources br label
Browse files Browse the repository at this point in the history
Signed-off-by: YuChen <[email protected]>
  • Loading branch information
YCShen1010 committed Nov 22, 2024
1 parent 96dcfd4 commit ac4a79c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions velero/backup/common-service/label-common-service.sh
Original file line number Diff line number Diff line change
Expand Up @@ -376,15 +376,16 @@ function label_cs(){
function label_nss(){
title "Label Namespacescope resources"
local nss_pm="ibm-namespace-scope-operator"
${OC} label subscriptions.operators.coreos.com $nss_pm foundationservices.cloudpak.ibm.com=nss -n $OPERATOR_NS --overwrite=true 2>/dev/null
# Using the same label as common service operator has for both sub and crd
${OC} label subscriptions.operators.coreos.com $nss_pm foundationservices.cloudpak.ibm.com=subscription -n $OPERATOR_NS --overwrite=true 2>/dev/null
${OC} label customresourcedefinition namespacescopes.operator.ibm.com foundationservices.cloudpak.ibm.com=crd --overwrite=true 2>/dev/null
# The following resources are labeled with 'nss' are bundled together for backup
${OC} label namespacescopes.operator.ibm.com common-service foundationservices.cloudpak.ibm.com=nss -n $OPERATOR_NS --overwrite=true 2>/dev/null
${OC} label customresourcedefinition namespacescopes.operator.ibm.com foundationservices.cloudpak.ibm.com=nss --overwrite=true 2>/dev/null
${OC} label serviceaccount ibm-namespace-scope-operator foundationservices.cloudpak.ibm.com=nss -n $OPERATOR_NS --overwrite=true 2>/dev/null
${OC} label role nss-managed-role-from-$OPERATOR_NS foundationservices.cloudpak.ibm.com=nss -n $OPERATOR_NS --overwrite=true 2>/dev/null
${OC} label role nss-managed-role-from-$OPERATOR_NS foundationservices.cloudpak.ibm.com=nss -n $SERVICES_NS --overwrite=true 2>/dev/null
${OC} label rolebinding nss-managed-role-from-$OPERATOR_NS foundationservices.cloudpak.ibm.com=nss -n $OPERATOR_NS --overwrite=true 2>/dev/null
${OC} label rolebinding nss-managed-role-from-$OPERATOR_NS foundationservices.cloudpak.ibm.com=nss -n $SERVICES_NS --overwrite=true 2>/dev/null
${OC} label configmap namespace-scope foundationservices.cloudpak.ibm.com=nss -n $OPERATOR_NS --overwrite=true 2>/dev/null
if [[ $TETHERED_NS != "" ]]; then
for namespace in ${TETHERED_NS//,/ }
do
Expand Down

0 comments on commit ac4a79c

Please sign in to comment.