-
Notifications
You must be signed in to change notification settings - Fork 63
35 lines (35 loc) · 1.01 KB
/
update-docs.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
# Upload website
on:
push:
branches:
- main
name: Upload website
jobs:
build:
name: build-upload
runs-on: ubuntu-latest
if: "contains(github.event.head_commit.message, 'update docs')"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-2
- name: Install deps (with cache)
uses: bahmutov/npm-install@v1
with:
working-directory: website
- name: Build website
run: |
cd website/
yarn build
- name: Upload
run: |
cd website/
aws s3 sync --delete build s3://jbrowse.org/jb2/
aws cloudfront create-invalidation --distribution-id E13LGELJOT4GQO --paths "/jb2/*"