From f2d2a48b96172c768ec81ed1f1962ece6eef6b87 Mon Sep 17 00:00:00 2001 From: Anas Nashif Date: Mon, 22 Nov 2021 10:16:14 -0500 Subject: [PATCH] actions: twister: add a cancel job very early on Cancel using GH runner for faster execution. Signed-off-by: Anas Nashif --- .github/workflows/twister.yaml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/twister.yaml b/.github/workflows/twister.yaml index 5d1973138a1..094d1a38cb6 100644 --- a/.github/workflows/twister.yaml +++ b/.github/workflows/twister.yaml @@ -12,8 +12,17 @@ on: - cron: '0 0 * * 6' jobs: + twister-build-cleanup: + runs-on: ubuntu-latest + steps: + - name: Cancel Previous Runs + uses: styfle/cancel-workflow-action@0.6.0 + with: + access_token: ${{ github.token }} + twister-build-prep: runs-on: zephyr_runner + needs: twister-build-cleanup container: image: zephyrprojectrtos/ci:v0.18.4 options: '--entrypoint /bin/bash' @@ -28,11 +37,6 @@ jobs: TESTS_PER_BUILDER: 700 COMMIT_RANGE: ${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }} steps: - - name: Cancel Previous Runs - uses: styfle/cancel-workflow-action@0.6.0 - with: - access_token: ${{ github.token }} - - name: checkout if: github.event_name == 'pull_request_target' uses: actions/checkout@v2