github.com/quay/claircore@v1.5.28/.github/workflows/updater-check-failures.yml (about)

     1  ---
     2  name: Create Issue on Updater Check Failure
     3  on:
     4    workflow_run:
     5      workflows: ['Updater Check']
     6      types:
     7        - completed
     8  
     9  jobs:
    10    on-failure:
    11      name: Failure
    12      runs-on: ubuntu-latest
    13      if: ${{ github.event.workflow_run.conclusion == 'failure' }}
    14      steps:
    15        - name: 'Create Issue'
    16          uses: actions/github-script@v7
    17          with:
    18            github-token: ${{ secrets.GITHUB_TOKEN }}
    19            script: |
    20              github.rest.issues.create({
    21                owner: context.repo.owner,
    22                repo: context.repo.repo,
    23                title: 'periodic: updater check failed',
    24                body: `See [output](${context.payload.workflow_run.logs_url}) for more.`,
    25                labels: ['robot'],
    26              })
    27