forked from anza-xyz/kit
-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (56 loc) · 1.86 KB
/
deploy-docs.yml
File metadata and controls
66 lines (56 loc) · 1.86 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
56
57
58
59
60
61
62
63
64
65
66
name: Deploy Documentation
on:
workflow_dispatch:
branches:
- main
push:
branches:
- main
permissions:
contents: read
pull-requests: write
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
# Among other things, opts out of Turborepo telemetry
# See https://consoledonottrack.com/
DO_NOT_TRACK: '1'
NEXT_TELEMETRY_DISABLED: '1'
VERCEL_TELEMETRY_DISABLED: '1'
# Enables Turborepo Remote Caching.
TURBO_REMOTE_CACHE_SIGNATURE_KEY: ${{ secrets.TURBO_REMOTE_CACHE_SIGNATURE_KEY }}
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ vars.TURBO_TEAM }}
jobs:
deploy-docs:
runs-on: ubuntu-latest
name: Deploy Documentation
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Dependencies
uses: ./.github/workflows/actions/install-dependencies
- name: Install Isolated Docs Dependencies
working-directory: ./docs/
shell: bash
run: pnpm install --ignore-workspace
- name: Install Vercel CLI
run: pnpm install -g vercel
- name: Deploy to Vercel
shell: bash
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_DOCS_PROJECT_ID }}
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
run: |
vercel pull --token="$VERCEL_TOKEN" --yes --environment=production
vercel build --token="$VERCEL_TOKEN" --prod
vercel deploy --token="$VERCEL_TOKEN" --archive=tgz --prebuilt --prod
- name: Synchronize InKeep Search Index
uses: inkeep/pr-commenter-action@84ccc7c74b72f628ec7e2b572e0cb7afd5898594 # v10
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
with:
apiKey: ${{secrets.INKEEP_SEARCH_MANAGEMENT_API_KEY}}
sourceId: '${{vars.INKEEP_SEARCH_SOURCE_ID}}'