forked from calcom/cal.diy
-
Notifications
You must be signed in to change notification settings - Fork 1
33 lines (32 loc) · 1.18 KB
/
cron-webhooks-triggers.yml
File metadata and controls
33 lines (32 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Cron - webhookTriggers
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 “every minute” (see https://crontab.guru)
- cron: "* * * * *"
jobs:
cron-webhookTriggers:
env:
APP_URL_US: ${{ vars.APP_URL_US }}
APP_URL_EU: ${{ vars.APP_URL_EU }}
CRON_API_KEY_US: ${{ secrets.CRON_API_KEY }}
CRON_API_KEY_EU: ${{ secrets.CRON_API_KEY_EU }}
runs-on: ubuntu-latest
steps:
- name: cURL request US
if: ${{ env.APP_URL_US && env.CRON_API_KEY_US }}
run: |
curl ${{ env.APP_URL_US }}/api/cron/webhookTriggers \
-X POST \
-H 'content-type: application/json' \
-H 'authorization: ${{ env.CRON_API_KEY_US }}' \
-sSf
- name: cURL request EU
if: ${{ env.APP_URL_EU && env.CRON_API_KEY_EU }}
run: |
curl ${{ env.APP_URL_EU }}/api/cron/webhookTriggers \
-X POST \
-H 'content-type: application/json' \
-H 'authorization: ${{ env.CRON_API_KEY_EU }}' \
-sSf