-
Notifications
You must be signed in to change notification settings - Fork 3
30 lines (26 loc) · 899 Bytes
/
Copy pathtask.yml
File metadata and controls
30 lines (26 loc) · 899 Bytes
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
name: Task
on:
push:
branches:
- main
paths:
- '**/*task.md'
jobs:
dev-docs-app:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Send Update to DevDocs
run: |
TIMESTAMP=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
API_KEY=${{ secrets.API_KEY }}
REPO_GH_PAT=${{secrets.REPO_GH_PAT}}
GITHUB_REPOSITORY="${{ github.repository }}"
GITHUB_ACTOR="${{ github.actor }}"
curl -X POST -H "Content-Type: application/json" \
-H "X-API-KEY: $API_KEY" \
-d '{"apiKey": "'$API_KEY'", "repo_gh_pat": "'$REPO_GH_PAT'", "timestamp": "'$TIMESTAMP'", "githubRepository": "'$GITHUB_REPOSITORY'", "githubActor": "'$GITHUB_ACTOR'"}' \
"${{ secrets.TASK_ENDPOINT }}"
env:
API_KEY: ${{ secrets.API_KEY }}