-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (52 loc) · 1.39 KB
/
deploy-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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: deploy-book
on:
workflow_dispatch:
push:
branches:
- 'main'
tags:
- '*'
jobs:
meta:
runs-on: self-hosted
outputs:
tag: ${{ steps.meta.outputs.version }}
steps:
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
deploy-book:
needs: meta
runs-on: self-hosted
container:
image: ghcr.io/robertrosca/julia-hpc-workshop:${{ needs.meta.outputs.tag }}
credentials:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v2
- name: Cache
uses: actions/cache@v1
env:
cache-name: jupyter_cache
with:
key: ${{ env.cache-name }}
path: ./_build/.jupyter_cache
- name: Setup
run: |
echo $JULIA_DEPOT_PATH
make setup
julia -e "using Pkg; Pkg.status()"
julia --project=@. -e "using Pkg; Pkg.status()"
- name: Build the book
run: |
export JULIA_PROJECT=$PWD
make html
- name: GitHub Pages action
uses: peaceiris/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./_build/html
destination_dir: ./${{ needs.meta.outputs.tag }}