Check SDR URLs (CRON) #955
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check SDR URLs (CRON) | |
on: | |
schedule: | |
- cron: "00 09 * * *" | |
workflow_dispatch: | |
jobs: | |
services-de-renseignement: | |
name: Check url from service de renseignement | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Test SDR urls | |
run: | | |
jq ".[].url" ./packages/code-du-travail-frontend/src/data/services-de-renseignement.json | uniq | xargs -n 1 wget --spider | |
- uses: mattermost/action-mattermost-notify@master | |
if: failure() | |
with: | |
MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }} | |
TEXT: |- | |
Une ou plusieurs URLs des services de renseignement ne sont plus valides ([logs](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})). |