Merge pull request #53 from Start9Labs/proxies #51
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Deploy mdBook site to Pages | |
| on: | |
| push: | |
| branches: ["master"] | |
| workflow_dispatch: | |
| # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| # Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. | |
| # However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: false | |
| jobs: | |
| # Build job | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install mdBook | |
| run: | | |
| MDBOOK_VERSION=$(curl -s https://api.github.com/repos/rust-lang/mdBook/releases/latest | jq -r '.tag_name') | |
| curl -sSL https://github.com/rust-lang/mdBook/releases/download/${MDBOOK_VERSION}/mdbook-${MDBOOK_VERSION}-x86_64-unknown-linux-gnu.tar.gz | tar -xz | |
| sudo mv mdbook /usr/local/bin/mdbook | |
| - name: Install mdBook Admonish | |
| run: | | |
| ADMONISH_VERSION=$(curl -s https://api.github.com/repos/tommilligan/mdbook-admonish/releases/latest | jq -r '.tag_name') | |
| curl -sSL https://github.com/tommilligan/mdbook-admonish/releases/download/${ADMONISH_VERSION}/mdbook-admonish-${ADMONISH_VERSION}-x86_64-unknown-linux-gnu.tar.gz | tar -xz | |
| sudo mv mdbook-admonish /usr/local/bin/mdbook-admonish | |
| - name: Install mdBook External Links | |
| run: | | |
| EXTERNAL_LINKS_VERSION=$(curl -s https://api.github.com/repos/jonahgoldwastaken/mdbook-external-links/releases/latest | jq -r '.tag_name') | |
| curl -sSL https://github.com/jonahgoldwastaken/mdbook-external-links/releases/download/${EXTERNAL_LINKS_VERSION}/mdbook-external-links-${EXTERNAL_LINKS_VERSION}-x86_64-unknown-linux-gnu.tar.gz | tar -xz | |
| sudo mv mdbook-external-links /usr/local/bin/mdbook-external-links | |
| - name: Configure mdBook Admonish | |
| run: mdbook-admonish install . | |
| - name: Setup Pages | |
| id: pages | |
| uses: actions/configure-pages@v5 | |
| - name: Build with mdBook | |
| run: mdbook build | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: ./docs | |
| # 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 |