Skip to content

Commit

Permalink
Use commit sha to change next version commit
Browse files Browse the repository at this point in the history
  • Loading branch information
muralov committed Feb 6, 2024
1 parent 4c3608a commit b98facc
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/e2e-upgrade-test-reusable.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@ on:
build-job-name:
type: string
description: "The name of the build job to wait for"
build-job-commit-sha:
commit-sha:
type: string
description: "The commit sha"
description: "The commit sha of the new version"
required: true

# PR: main -> PR
# main: release -> main
Expand Down Expand Up @@ -77,7 +78,7 @@ jobs:
uses: kyma-project/wait-for-commit-status-action@2b3ffe09af8b6f40e1213d5fb7f91a7bd41ffb20
with:
context: ${{ inputs.build-job-name }}
commit_ref: "${{ inputs.build-job-commit-sha }}" # Note: 'github.event.pull_request.head.sha' is not same as 'github.sha' on pull requests.
commit_ref: "${{ inputs.commit-sha }}"
timeout: 600000 # 10 minutes in milliseconds
# The check interval is kept long otherwise it will exhaust the GitHub rate limit (More info: https://docs.github.com/en/rest/overview/resources-in-the-rest-api?apiVersion=2022-11-28#rate-limiting)
check_interval: 60000 # 1 minute in milliseconds
Expand All @@ -88,6 +89,8 @@ jobs:

- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ inputs.commit-sha }}

- name: Install Eventing manager after upgrade
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pull-e2e-upgrade-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ jobs:
pre-upgrade-image-tag: main
post-upgrade-image-tag: PR-${{ github.event.number }}
build-job-name: pull-eventing-manager-build
build-job-commit-sha: ${{ github.event.pull_request.head.sha }}
commit-sha: ${{ github.event.pull_request.head.sha }}
secrets: inherit
2 changes: 1 addition & 1 deletion .github/workflows/push-e2e-upgrade-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@ jobs:
pre-upgrade-image-tag: ${{ needs.get-latest-release.outputs.latest_release_tag }}
post-upgrade-image-tag: main
build-job-name: post-eventing-manager-build
build-job-commit-sha: ${{ github.sha }}
commit-sha: ${{ github.sha }}
secrets: inherit

0 comments on commit b98facc

Please sign in to comment.