From f8ae65b3045843ef10ca1447741c5013b303b34a Mon Sep 17 00:00:00 2001 From: Filip Strozik Date: Thu, 2 Jan 2025 13:53:58 +0100 Subject: [PATCH] get rid of the verify-actions-status script (#365) --- .github/scripts/verify-actions-status.sh | 26 ------------------------ .github/workflows/create-release.yaml | 14 ------------- 2 files changed, 40 deletions(-) delete mode 100755 .github/scripts/verify-actions-status.sh diff --git a/.github/scripts/verify-actions-status.sh b/.github/scripts/verify-actions-status.sh deleted file mode 100755 index 1b022d15..00000000 --- a/.github/scripts/verify-actions-status.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env bash - -echo "Checking status of github actions for warden" - -REF_NAME="${1:-"main"}" -RAW_EXPECTED_SHA=$(git log "${REF_NAME}" --max-count 1 --format=format:%H) -REPOSITORY_ID="570927906" - -STATUS_URL="https://api.github.com/repositories/${REPOSITORY_ID}/actions/workflows/warden-verify.yaml/runs?head_sha=${RAW_EXPECTED_SHA}" -GET_STATUS_JQ_QUERY=".workflow_runs[0] | \"\(.status)-\(.conclusion)\"" -GET_COUNT_JQ_QUERY=".total_count" - -response=`curl -s ${STATUS_URL}` - -count=`echo $response | jq -r "${GET_COUNT_JQ_QUERY}"` -if [[ "$count" == "0" ]]; then - echo "No actions to verify" -else - fullstatus=`echo $response | jq -r "${GET_STATUS_JQ_QUERY}"` - if [[ "$fullstatus" == "completed-success" ]]; then - echo "All actions succeeded" - else - echo "Actions failed or pending - Check github actions status" - exit 1 - fi -fi diff --git a/.github/workflows/create-release.yaml b/.github/workflows/create-release.yaml index 14ae79ea..61a1f94a 100644 --- a/.github/workflows/create-release.yaml +++ b/.github/workflows/create-release.yaml @@ -17,22 +17,8 @@ permissions: # used by build images steps contents: write # This is required for actions/checkout jobs: - verify-head-status: - name: Verify HEAD - runs-on: ubuntu-latest - - steps: - - name: Checkout code - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Verify github actions - run: ./.github/scripts/verify-actions-status.sh ${{ github.ref_name }} - upgrade-images: name: Upgrade main images - needs: verify-head-status runs-on: ubuntu-latest steps: