-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (57 loc) · 1.7 KB
/
deploy_docs.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
---
name: "Build and deploy docs"
on: # yamllint disable-line rule:truthy
push:
tags: ["*"]
# FIXME: do not build docs on each PR or push
pull_request:
branches: ["*"]
workflow_dispatch:
permissions:
contents: read
id-token: write
pages: write
concurrency:
cancel-in-progress: false
group: "pages"
jobs:
build_docs:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: "Checkout git repository"
uses: actions/checkout@v4
- name: "DEBUG ME docker pull"
run: "docker pull ghcr.io/maximiliankolb/docs:1.0.0"
- name: "DEBUG ME docker tag"
run: "docker tag ghcr.io/maximiliankolb/docs:1.0.0 docs"
- name: "Check tree"
run: "tree"
- name: "Workaround to use podman in Makefile"
run: sed -i "s/podman/docker/g" Makefile
- name: "Workaround to use minimal container image"
run: sed -i "s/docs-minimal/docs/g" Makefile
- name: "Workaround to use non-interactive container in Makefile"
run: sed -i "s/-it//g" Makefile
- name: "Build docs"
run: make html
- name: "Check tree again"
run: "tree"
# - name: "Create archive"
# run: make archive
- name: "Rename built docs"
run: mv -f docs/output github-pages
- name: "Check tree another time"
run: "tree"
- name: "Setup Github Pages"
uses: actions/configure-pages@v5
- name: "Upload built docs"
uses: actions/upload-pages-artifact@v3
with:
path: "github-pages.tar.gz"
- name: "Deploy to GitHub Pages"
id: deployment
uses: actions/deploy-pages@v4
...