-
-
Notifications
You must be signed in to change notification settings - Fork 681
39 lines (32 loc) · 1.01 KB
/
doc-deploy.yml
File metadata and controls
39 lines (32 loc) · 1.01 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
name: Deploy Documentation
on:
push:
branches: [main]
paths:
- "docs/**"
- ".github/workflows/doc-deploy.yml"
env:
LAF_CI_DOCS_PREVIEW_PAT: ${{ secrets.LAF_CI_DOCS_PREVIEW_PAT }}
LAF_CI_DOCS_PREVIEW_APPID: ${{ secrets.LAF_CI_DOCS_PREVIEW_APPID }}
LAF_CI_DOCS_PREVIEW_API_URL: ${{ secrets.LAF_CI_DOCS_PREVIEW_API_URL }}
jobs:
deploy-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Build Docs
uses: ./.github/actions/build-docs
- name: Setup laf-cli
run: npm i laf-cli -g
- name: Login laf-cli
run: |
laf user add doc -r ${{ env.LAF_CI_DOCS_PREVIEW_API_URL }}
laf user switch doc
laf login ${{ env.LAF_CI_DOCS_PREVIEW_PAT }}
laf app init ${{ env.LAF_CI_DOCS_PREVIEW_APPID }}
- name: Deploy to production bucket
run: |
# Deploy to production docs bucket
laf storage push -f production-docs docs/.vitepress/dist/