fix(ci): new PR comments cancel ongoing ephemeral builds (#27085)

This commit is contained in:
Daniel Vaz Gaspar 2024-02-12 16:59:24 +00:00 committed by GitHub
parent 6c5e8fa175
commit 16e49cb2f7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 5 deletions

View File

@ -4,11 +4,6 @@ on:
issue_comment:
types: [created]
# cancel previous workflow jobs for PRs
concurrency:
group: ${{ github.workflow }}-${{ github.event.issue.number || github.run_id }}
cancel-in-progress: true
jobs:
config:
runs-on: "ubuntu-latest"
@ -25,6 +20,9 @@ jobs:
fi
ephemeral-env-comment:
concurrency:
group: ${{ github.workflow }}-${{ github.event.issue.number || github.run_id }}-comment
cancel-in-progress: true
needs: config
if: needs.config.outputs.has-secrets
name: Evaluate ephemeral env comment trigger (/testenv)
@ -85,6 +83,9 @@ jobs:
core.setFailed(errMsg)
ephemeral-docker-build:
concurrency:
group: ${{ github.workflow }}-${{ github.event.issue.number || github.run_id }}-build
cancel-in-progress: true
needs: ephemeral-env-comment
name: ephemeral-docker-build
runs-on: ubuntu-latest