forked from sigp/anchor
-
Notifications
You must be signed in to change notification settings - Fork 1
37 lines (31 loc) · 949 Bytes
/
book.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
36
37
name: mdbook
on:
push:
branches:
- unstable
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build-and-upload-to-s3:
if: github.repository_owner == 'sigp'
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Setup mdBook
uses: jontze/action-mdbook@v3
with:
token: ${{secrets.GITHUB_TOKEN}}
use-mermaid: true
use-linkcheck: true
- run: mdbook build
working-directory: book
- uses: jakejarvis/s3-sync-action@be0c4ab89158cac4278689ebedd8407dd5f35a83
with:
args: --follow-symlinks --delete
env:
AWS_S3_BUCKET: ${{ secrets.AWS_S3_BOOK_BUCKET }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: 'ap-southeast-2'
SOURCE_DIR: 'book/book'