-
Notifications
You must be signed in to change notification settings - Fork 1
40 lines (38 loc) · 1.09 KB
/
sphinx-pages.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
name: Build and Deploy
on:
push:
branches:
162-protect-deployment-to-github-pages
permissions:
id-token: write # Add this line to allow OIDC token access
pages: write
jobs:
build:
# Specify runner + build & upload the static files as an artifact
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- name: Install dependencies
run: |
pip install sphinx sphinx_rtd_theme myst_parser sphinxcontrib-mermaid
- name: Build static files
id: build
run: |
sphinx-build webcentral/doc/06_sphinx/source build/
- name: Upload static files as artifact
id: deployment
uses: actions/upload-pages-artifact@v3 # or specific "vX.X.X" version tag for this action
with:
path: build/
# Deployment job
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4