diff --git a/.github/workflows/cf-pages.yml b/.github/workflows/cf-pages.yml new file mode 100644 index 0000000..85694ae --- /dev/null +++ b/.github/workflows/cf-pages.yml @@ -0,0 +1,30 @@ +name: Deploy to Cloudflare Pages + +on: + push: + branches: + - main + paths: + - 'html/**' + workflow_dispatch: + +jobs: + deploy: + runs-on: ubuntu-latest + permissions: + contents: read + deployments: write + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Deploy to Cloudflare Pages + uses: cloudflare/pages-action@v1 + with: + apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} + accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} + projectName: ${{ secrets.CLOUDFLARE_PROJECT_NAME }} + directory: html + gitHubToken: ${{ secrets.GITHUB_TOKEN }} + wranglerVersion: '3'