-
Bug
-
Resolution: Won't Do
-
Medium
-
None
-
Frankfurt Release
-
None
-
SDNC Fr Sp4:1/6-1/24
If you use a helm override file with the deploy command it can result in unexpected results if it contains the global: "tag"
I think the problem comes from the code in the .helm/plugins/deploy/deploy.sh
[ 45|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l45] generate_overrides() {
[ 46|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l46] SUBCHART_NAMES=($(cat $COMPUTED_OVERRIDES | grep -v '^\s\s'))
[ 47|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l47]
[ 48|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l48] for index in "${!SUBCHART_NAMES[@]}"; do
[ 49|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l49] START=${SUBCHART_NAMES[index]}
[ 50|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l50] END=${SUBCHART_NAMES[index+1]}
[ 51|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l51] if [[ $START == "global:" ]]; then
[ 52|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l52] echo "global:" > $GLOBAL_OVERRIDES
[ 53|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l53] cat $COMPUTED_OVERRIDES | sed '/common:/,/consul:/d' \
[ 54|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l54] | sed -n '/'"$START"'/,/'log:'/p' | sed '1d;$d' >> $GLOBAL_OVERRIDES
[ 55|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l55] else
[ 56|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l56] SUBCHART_DIR="$CACHE_SUBCHART_DIR/$(cut -d':' -f1 <<<"$START")"
[ 57|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l57] if [[ -d "$SUBCHART_DIR" ]]; then
[ 58|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l58] if [[ -z "$END" ]]; then
[ 59|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l59] cat $COMPUTED_OVERRIDES | sed -n '/^'"$START"'/,/'"$END"'/p' \
[ 60|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l60] | sed '1d;$d' | cut c3 > $SUBCHART_DIR/subchart-overrides.yaml
[ 61|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l61] else
[ 62|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l62] cat $COMPUTED_OVERRIDES | sed -n '/'"$START"'/,/'"$END"'/p' \
[ 63|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l63] | sed '1d;$d' | cut c3 > $SUBCHART_DIR/subchart-overrides.yaml
[ 64|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l64] fi
[ 65|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l65] fi
[ 66|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l66] fi
[ 67|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l67] done
[ 68|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l68] }
comparing how the sub charts are extracted I think the global section should be like
53 cat $COMPUTED_OVERRIDES \
[ 54|https://gerrit.onap.org/r/gitweb?p=oom.git;a=blob;f=kubernetes/helm/plugins/deploy/deploy.sh;h=c92bc6e8b1b23d62521276f27af721eca442a174;hb=HEAD#l54] | sed -n '/'"$START"'/,/'"$END"'/p' | sed '1d;$d' >> $GLOBAL_OVERRIDES