Merge pull request #8861 from Icinga/bugfix/gha-cancel-212

GitHub actions: auto-cancel previous jobs for the same PR
This commit is contained in:
Julian Brost 2021-07-05 11:33:58 +02:00 committed by GitHub
commit 1d714a887c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 28 additions and 0 deletions

View File

@ -15,6 +15,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Cancel previous jobs for the same PR
if: "github.event_name == 'pull_request'"
uses: styfle/cancel-workflow-action@89f242ee29e10c53a841bfe71cc0ce7b2f065abc
with:
workflow_id: docker.yml,packages.yml
access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Docker image
uses: Icinga/docker-icinga2@master
env:

View File

@ -37,6 +37,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Cancel previous jobs for the same PR
if: "github.event_name == 'pull_request'"
uses: styfle/cancel-workflow-action@89f242ee29e10c53a841bfe71cc0ce7b2f065abc
with:
workflow_id: docker.yml,packages.yml
access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Checkout HEAD
uses: actions/checkout@v1
@ -141,6 +148,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Cancel previous jobs for the same PR
if: "github.event_name == 'pull_request'"
uses: styfle/cancel-workflow-action@89f242ee29e10c53a841bfe71cc0ce7b2f065abc
with:
workflow_id: docker.yml,packages.yml
access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Vars
id: vars
env:
@ -227,6 +241,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Cancel previous jobs for the same PR
if: "github.event_name == 'pull_request'"
uses: styfle/cancel-workflow-action@89f242ee29e10c53a841bfe71cc0ce7b2f065abc
with:
workflow_id: docker.yml,packages.yml
access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Checkout HEAD
uses: actions/checkout@v1