Skip to content

Commit

Permalink
fix: release script (#1427)
Browse files Browse the repository at this point in the history
Signed-off-by: Anatolii Bazko <abazko@redhat.com>
  • Loading branch information
tolusha authored Jul 1, 2022
1 parent 7f86e7d commit 92b7a27
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -211,13 +211,16 @@ update-helmcharts: ## Update Helm Charts
CRDS_SAMPLES=$${CRDS_SAMPLES}$${CRD_SAMPLE}$$'\n'
done

# Update Chart.yaml
yq -rYi --arg examples "$${CRDS_SAMPLES}" ".annotations.\"artifacthub.io/crdsExamples\" = \$$examples" $${chartYaml}

# Set CheCluster API version to v2 (TODO: remove in a next release)
CRDS=$$(yq -r '.annotations."artifacthub.io/crds"' $${chartYaml} | yq -ry -w 9999 '.[0].version="v2"')
yq -rYi --arg crds "$${CRDS}" ".annotations.\"artifacthub.io/crds\" = \$$crds" $${chartYaml}
sed -i 's|org_v1_checluster|org_v2_checluster|g' $${HELM_DIR}/README.md

make license $${chartYaml}

rm -rf $${HELMCHARTS_TEMPLATES}/org_v2_checluster.yaml
else
yq -riY '.spec.networking = null' $${HELMCHARTS_TEMPLATES}/org_v2_checluster.yaml
Expand Down
4 changes: 4 additions & 0 deletions olm/release-olm-files.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,10 @@ cp -rf "${NEXT_BUNDLE_PATH}/bundle.Dockerfile" "${STABLE_BUNDLE_PATH}"
cp -rf "${NEXT_BUNDLE_PATH}/metadata" "${STABLE_BUNDLE_PATH}"
cp -rf "${NEXT_BUNDLE_PATH}/tests" "${STABLE_BUNDLE_PATH}"

# Remove old CRD files (TODO remove in future release)
rm "${NEXT_BUNDLE_PATH}/manifests/org_v1_che_crd.yaml"
rm "${NEXT_BUNDLE_PATH}/manifests/org_v1_che_crd.yaml.diff"

ANNOTATION_METADATA_YAML="${STABLE_BUNDLE_PATH}/metadata/annotations.yaml"
sed \
-e 's/operators.operatorframework.io.bundle.channels.v1: .*/operators.operatorframework.io.bundle.channels.v1: '$CHANNEL'/' \
Expand Down

0 comments on commit 92b7a27

Please sign in to comment.