mirror of
https://github.com/element-hq/matrix-authentication-service.git
synced 2026-05-04 11:45:43 +00:00
49 lines
1019 B
YAML
49 lines
1019 B
YAML
name: Build and deploy the documentation
|
|
|
|
on:
|
|
push:
|
|
branches: [ main ]
|
|
pull_request:
|
|
branches: [ main ]
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
build:
|
|
name: Build the documentation
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout the code
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Setup mdBook
|
|
uses: peaceiris/actions-mdbook@v1.2.0
|
|
with:
|
|
mdbook-version: '0.4.25'
|
|
|
|
- name: Build the documentation
|
|
run: mdbook build
|
|
|
|
- name: Upload GitHub Pages artifacts
|
|
uses: actions/upload-pages-artifact@v1.0.7
|
|
|
|
deploy:
|
|
name: Deploy the documentation on GitHub Pages
|
|
runs-on: ubuntu-latest
|
|
needs: build
|
|
|
|
permissions:
|
|
pages: write
|
|
id-token: write
|
|
|
|
environment:
|
|
name: github-pages
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
|
|
steps:
|
|
- name: Deploy to GitHub Pages
|
|
id: deployment
|
|
uses: actions/deploy-pages@v1.2.3
|