Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate GitHub Pages deployment away from the static-websites action #231

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 19 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,24 @@ jobs:
- run: bash ci/spellcheck.sh list
- run: mdbook build
- run: cargo test --all --manifest-path=./examples/Cargo.toml --target-dir ./target
- uses: rust-lang/simpleinfra/github-actions/static-websites@master
- uses: actions/upload-pages-artifact@v3
with:
deploy_dir: book/html
github_token: ${{ secrets.GITHUB_TOKEN }}
path: book/html
if: github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository_owner == 'rust-lang'

# Deploy is run as a separate job as it needs elevated permissions
deploy:
name: deploy
needs: test # the `test` job uploads the pages artifact
if: github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository_owner == 'rust-lang'
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{steps.deployment.outputs.page_url}}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
uses: actions/deploy-pages@v4
id: deployment
Loading