Skip to content

Commit 3a8b36b

Browse files
committed
Fix Helm release logic
1 parent c7166b7 commit 3a8b36b

1 file changed

Lines changed: 5 additions & 6 deletions

File tree

.github/workflows/release.yaml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,7 @@ jobs:
5151
- name: Set version
5252
run: |
5353
TAG="${GITHUB_REF#refs/*/}"
54-
echo "APP_VERSION=$TAG" >> $GITHUB_ENV
55-
echo "VERSION=${TAG#v}" >> $GITHUB_ENV
54+
echo "TAG=$TAG" >> $GITHUB_ENV
5655
- name: Checkout
5756
uses: actions/checkout@v6
5857
with:
@@ -68,16 +67,16 @@ jobs:
6867
version: v4.1.1
6968
- name: Verify version
7069
run: |
71-
if yq e ".version == strenv(VERSION)" charts/keycloak-cr-operator/Chart.yaml; then
70+
if yq e ".version == strenv(TAG)" charts/keycloak-cr-operator/Chart.yaml; then
7271
echo "Chart version matches"
7372
else
74-
echo "Tag version $VERSION does not match Chart.yaml version"
73+
echo "Tag $TAG does not match Chart.yaml version"
7574
exit 1
7675
fi
77-
if yq e ".appVersion == strenv(APP_VERSION)" charts/keycloak-cr-operator/Chart.yaml; then
76+
if yq e ".appVersion == strenv(TAG)" charts/keycloak-cr-operator/Chart.yaml; then
7877
echo "Chart appVersion matches"
7978
else
80-
echo "App version from tag $APP_VERSION does not match Chart.yaml version"
79+
echo "Tag $TAG does not match Chart.yaml appVersion"
8180
exit 1
8281
fi
8382
- name: Publish Helm charts

0 commit comments

Comments
 (0)