diff --git a/.github/workflows/pr-integration.yml b/.github/workflows/pr-integration.yml index 4cefd1269..db1ac0bf0 100644 --- a/.github/workflows/pr-integration.yml +++ b/.github/workflows/pr-integration.yml @@ -1,7 +1,8 @@ name: PR Integration env: - IMG: europe-docker.pkg.dev/kyma-project/dev/telemetry-manager:PR-${{ github.event.number }} + # add the tag PR- to the image if it is a PR, if the trigger is merge_group, then add the sha as the tag + IMG: europe-docker.pkg.dev/kyma-project/dev/telemetry-manager:${{ github.event_name == 'pull_request' && 'PR-' || '' }}${{ github.event.number || github.event.merge_group.head_sha }} on: merge_group: diff --git a/.github/workflows/pr-lifecycle.yml b/.github/workflows/pr-lifecycle.yml index 0ca913dd8..213f2d9e1 100644 --- a/.github/workflows/pr-lifecycle.yml +++ b/.github/workflows/pr-lifecycle.yml @@ -70,7 +70,9 @@ jobs: - name: Deploy with current version shell: bash run: | - IMG=europe-docker.pkg.dev/kyma-project/dev/telemetry-manager:PR-${{ github.event.number }} make deploy-dev + # add the tag PR- to the image if it is a PR, if the trigger is merge_group, then add the sha as the tag + TAG="${{ github.event_name == 'pull_request' && 'PR-' || '' }}${{ github.event.number || github.event.merge_group.head_sha }}" + IMG=europe-docker.pkg.dev/kyma-project/dev/telemetry-manager:${TAG} make deploy-dev - name: Wait for manager readiness shell: bash