Skip to content

ci: Wrangler website deployer #56

ci: Wrangler website deployer

ci: Wrangler website deployer #56

name: Website
on:
pull_request:
branches: [main]
paths:
- 'docs/**'
- ".github/workflows/test-website-a11y.yml"
env:
JEKYLL_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
test:
name: test a11y
runs-on: ubuntu-latest
steps:
- name: Checkout source
uses: actions/checkout@v4
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
working-directory: docs
ruby-version: 3.2
- name: Install GEMs
working-directory: docs
env:
BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile
run: |
pwd
bundle install
- name: Build site
working-directory: docs
env:
BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile
run: bundle exec jekyll build
- name: Serve site
working-directory: docs
env:
BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile
run: bundle exec jekyll serve --detach
- name: Show environment
working-directory: docs
run: npx pa11y --environment
- name: Test accessibility
working-directory: docs
run: |
npx pa11y-ci \
--sitemap http://127.0.0.1:4000/sitemap.xml \
--sitemap-exclude "/*.pdf"
- name: Kill site (failsafe)
if: always()
run: pkill -f jekyll