-
Notifications
You must be signed in to change notification settings - Fork 7
46 lines (38 loc) · 1.14 KB
/
gen-rest-api.yml
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
34
35
36
37
38
39
40
41
42
43
44
45
46
name: "Generate REST-API data"
on:
pull_request:
workflow_dispatch:
concurrency:
group: "main-${{ github.ref_name }}-${{ github.workflow }}"
cancel-in-progress: true
jobs:
update-restapi-data:
runs-on: ubuntu-latest
steps:
# Setup pulp instance
- uses: "actions/checkout@v4"
with:
fetch-depth: 0
path: "pulp-docs"
- uses: "actions/checkout@v4"
with:
fetch-depth: 1
repository: "pulp/pulp-openapi-generator"
path: "pulp-openapi-generator"
- uses: "actions/setup-python@v4"
with:
python-version: "3.11"
- name: "Setup and run Pulp instance"
run: "pulp-docs/.github/workflows/scripts/setup-pulp.sh"
# Generate api.json
- name: "Generate api.json OpenApi schema"
run: |
echo "Generating OpenAPI schema"
# Commit api.json
- name: "Configure Git with pulpbot name and email"
run: |
git config --global user.name 'pulpbot'
git config --global user.email '[email protected]'
- name: commit-changes
run: |
echo "Commiting changes"