Skip to content

Commit

Permalink
Create health-check.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
guibranco authored Oct 28, 2023
1 parent 9d89170 commit 769989d
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/health-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Ping Healthchecks.io

on:
workflow_run:
workflows: ['Update packages']
types: [requested, completed]

jobs:

Ping-Started:
runs-on: ubuntu-latest
if: ${{ github.event.action == 'requested' }}
steps:
- run: curl -m 10 --retry 5 ${{ secrets.ping_url }}/start

Ping-Success:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- run: curl -m 10 --retry 5 ${{ secrets.ping_url }}

Ping-Failure:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
steps:
- run: curl -m 10 --retry 5 ${{ secrets.ping_url }}/fail

0 comments on commit 769989d

Please sign in to comment.