-
Notifications
You must be signed in to change notification settings - Fork 54
41 lines (37 loc) · 1.08 KB
/
docs-ci-previews.yaml
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
# .github/workflows/preview.yml
name: "docs.estuary.dev: Deploy PR previews"
on:
pull_request:
paths:
- site/**
types:
- opened
- reopened
- synchronize
- closed
concurrency: preview-${{ github.ref }}
permissions:
contents: write
pull-requests: write
jobs:
deploy-preview:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
cache-dependency-path: ./site/package-lock.json
- name: Install dependencies
working-directory: ./site
run: npm ci
- name: Build `docs.estuary.dev`
working-directory: ./site
env:
BASE_URL: /pr-preview/pr-${{ github.event.number }}
run: npm run build
- name: Deploy preview
uses: rossjrw/pr-preview-action@v1
with:
source-dir: ./site/build/