-
Notifications
You must be signed in to change notification settings - Fork 3
55 lines (52 loc) · 1.52 KB
/
deploy-api-docs.yml
File metadata and controls
55 lines (52 loc) · 1.52 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: deploy-api-docs
on:
workflow_call:
inputs:
name:
type: string
workflow_dispatch:
inputs:
name:
type: string
env:
CARGO_TERM_COLOR: always
jobs:
deploy-api-docs:
name: Deploy API documentation
runs-on: ubuntu-latest
environment: main
steps:
- name: Install Protoc
uses: arduino/setup-protoc@v2
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/checkout@v6
with:
path: main
- uses: actions/checkout@v6
with:
path: release
ref: refs/tags/release
- uses: Swatinem/rust-cache@v2
with:
workspaces: |
main
release
cache-on-failure: true
- uses: superfly/flyctl-actions/setup-flyctl@master
with:
version: 0.4.6
- run: ./build.sh . ${{ inputs.name || github.ref_name }}
working-directory: main/docs/api
- run: ../../../main/docs/api/build.sh ../../../main/docs/api release
working-directory: release/docs/api
env:
# For backwards compatibility with compile-time environment variables.
OPEN_PDKS_ROOT: ""
SKY130_CDS_PDK_ROOT: ""
- run: echo "<meta http-equiv=\"refresh\" content=\"0; url=release/substrate\">" > ./static/index.html
working-directory: main/docs/api
- run: flyctl deploy --remote-only --detach
working-directory: main/docs/api
env:
FLY_ACCESS_TOKEN: ${{ secrets.FLY_API_TOKEN_API }}