Skip to content

Cancel workflow runs #12554

Cancel workflow runs

Cancel workflow runs #12554

name: "Cancel workflow runs"
on:
workflow_run:
workflows:
- "GLPI CI"
- "GLPI test code coverage"
types:
- requested
jobs:
cancel:
permissions:
actions: write # for styfle/cancel-workflow-action to cancel/stop running workflows
runs-on: "${{ github.repository == 'glpi-network/glpi' && 'self-hosted' || 'ubuntu-latest' }}"
steps:
- name: "Cancel outdated workflow runs"
uses: "styfle/[email protected]"
with:
all_but_latest: true
workflow_id: ${{ github.event.workflow.id }}