@@ -133,37 +133,26 @@ update_code() {
133133 # Not all operators have a getting started guide
134134 # that's why we verify if templating_vars.yaml exists.
135135 if [ -f " $1 /docs/templating_vars.yaml" ]; then
136- yq -i " (.versions.[] | select(. == \" *dev\" )) |= \" ${RELEASE } \" " " $1 /docs/templating_vars.yaml"
136+ yq -i " (.versions.[] | select(. == \" *dev\" )) |= \" ${RELEASE_TAG } \" " " $1 /docs/templating_vars.yaml"
137137 yq -i " .helm.repo_name |= sub(\" stackable-dev\" , \" stackable-stable\" )" " $1 /docs/templating_vars.yaml"
138138 yq -i " .helm.repo_url |= sub(\" helm-dev\" , \" helm-stable\" )" " $1 /docs/templating_vars.yaml"
139139 fi
140140
141141 # --------------------------------------------------------------------------
142- # Replace .spec.image.stackableVersion for getting-started examples .
143- # N.B. yaml files should contain a single document .
142+ # Replace .spec.image.stackableVersion for kuttl tests .
143+ # Use sed as yq does not process .j2 file syntax properly .
144144 # --------------------------------------------------------------------------
145- if [ -d " $1 /docs/modules/getting_started/examples/code" ]; then
146- for file in $( find " $1 /docs/modules/getting_started/examples/code" -name " *.yaml" ) ; do
147- yq -i " (.spec | select(has(\" image\" )).image | (select(has(\" stackableVersion\" )).stackableVersion)) = \" ${RELEASE} \" " " $file "
148- done
145+ if [ -f " $1 /tests/test-definition.yaml" ]; then
146+ # e.g. 2.2.4-stackable0.5.0 -> 2.2.4-stackable23.1
147+ sed -i " s/-stackable.*/-stackable${RELEASE} /" " $1 /tests/test-definition.yaml"
149148 fi
150149
151- # --------------------------------------------------------------------------
152- # Replace .spec.image.stackableVersion for kuttl tests.
153- # Use sed as yq does not process .j2 file syntax properly.
154- # --------------------------------------------------------------------------
155- # TODO old product images won't be tested any longer
156- if [ -f " $1 /tests/test-definition.yaml" ]; then
157- # e.g. 2.2.4-stackable0.5.0 -> 2.2.4-stackable23.1
158- sed -i " s/-stackable.*/-stackable${RELEASE} /" " $1 /tests/test-definition.yaml"
159- fi
160-
161- # --------------------------------------------------------------------------
162- # Replace "nightly" link so the documentation refers to the current version
163- # --------------------------------------------------------------------------
164- for file in $( find " $1 /docs" -name " *.adoc" ) ; do
165- sed -i " s/nightly@home/home/g" " $file "
166- done
150+ # --------------------------------------------------------------------------
151+ # Replace "nightly" link so the documentation refers to the current version
152+ # --------------------------------------------------------------------------
153+ for file in $( find " $1 /docs" -name " *.adoc" ) ; do
154+ sed -i " s/nightly@home/home/g" " $file "
155+ done
167156}
168157
169158push_branch () {
0 commit comments