Files
cal-diy-oidc/.github/workflows/cron-scheduleWhatsappReminders.yml
T
Alex van Andel 6daac15bea fix: GH based cronjobs in EU (#25992)
* fix: GH based cronjobs in EU

* Some fixups

* Some further fixes
2025-12-26 11:43:28 +00:00

34 lines
1.2 KiB
YAML

name: Cron - scheduleWhatsappReminders
on:
# "Scheduled workflows run on the latest commit on the default or base branch."
# — https://docs.github.com/en/actions/learn-github-actions/events-that-trigger-workflows#schedule
schedule:
# Runs "At every 15th minute." (see https://crontab.guru)
- cron: "*/15 * * * *"
jobs:
cron-scheduleWhatsappReminders:
env:
APP_URL_EU: ${{ vars.APP_URL_EU }}
APP_URL_US: ${{ vars.APP_URL_US }}
CRON_API_KEY_EU: ${{ secrets.CRON_API_KEY_EU }}
CRON_API_KEY_US: ${{ secrets.CRON_API_KEY }}
runs-on: ubuntu-latest
steps:
- name: cURL request EU
if: ${{ env.APP_URL_EU && env.CRON_API_KEY_EU }}
run: |
curl ${{ env.APP_URL_EU }}/api/cron/workflows/scheduleWhatsappReminders \
-X POST \
-H 'content-type: application/json' \
-H 'authorization: ${{ env.CRON_API_KEY_EU }}' \
-sSf
- name: cURL request US
if: ${{ env.APP_URL_US && env.CRON_API_KEY_US }}
run: |
curl ${{ env.APP_URL_US }}/api/cron/workflows/scheduleWhatsappReminders \
-X POST \
-H 'content-type: application/json' \
-H 'authorization: ${{ env.CRON_API_KEY_US }}' \
-sSf