From 4d54a20c17c41113fc2400e4e4b31757f3e776fb Mon Sep 17 00:00:00 2001 From: anton Date: Wed, 3 Apr 2024 14:26:14 +0200 Subject: [PATCH] Changed user to repository_owner and tuned version calculating --- .github/workflows/package_and_push_helm_chart.yaml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/package_and_push_helm_chart.yaml b/.github/workflows/package_and_push_helm_chart.yaml index 7461ce20d..5bfde54a6 100644 --- a/.github/workflows/package_and_push_helm_chart.yaml +++ b/.github/workflows/package_and_push_helm_chart.yaml @@ -5,6 +5,7 @@ on: branches: - dev - release + - devops/FAIRSPC-23_deployment workflow_dispatch: inputs: name: @@ -33,15 +34,20 @@ jobs: - name: Prepare version run: | VERSION=$(cat ./VERSION) + echo "Helm charts version to be deployed (preliminary-0): $VERSION" BRANCH=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}} - if [ $BRANCH != "release" ] - then + echo "Building images from the branch: $BRANCH" + if [ $BRANCH != "release" ]; then VERSION=$VERSION-SNAPSHOT fi + echo "Helm charts version to be deployed (preliminary): $VERSION" # override version of custom input is provided - if [ "${{ github.event.inputs.version != '' }}" ]; then + echo "${{ github.event.inputs.version != '' }}" + if [[ -n "${{ github.event.inputs.version }}" }}" ]]; then + echo "Overriding version with input" VERSION=${{ github.event.inputs.version }} fi + echo "Helm charts version to be deployed: $VERSION" echo "VERSION=$VERSION" >> $GITHUB_ENV - name: Push Helm chart to repository