Skip to content

Scheduled Pages Rebuild #89

Scheduled Pages Rebuild

Scheduled Pages Rebuild #89

name: Scheduled Pages Rebuild
on:
schedule:
- cron: '0 14 * * *' # every day at 14:00 UTC → 07:00 PDT
workflow_dispatch:
# give the workflow permission to kick off a Pages build
permissions:
contents: read # we don’t need to write code
pages: write # allows GITHUB_TOKEN to call the Pages Builds API
jobs:
rebuild:
runs-on: ubuntu-latest
steps:
- name: Trigger GitHub Pages build
run: |
curl -X POST \
-H "Accept: application/vnd.github.ant-man-preview+json" \
-H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
https://api.github.com/repos/${{ github.repository }}/pages/builds