Skip to content

Commit 0d1c5d9

Browse files
committed
Update deployment to push to cloudflare pages
1 parent 017e5fa commit 0d1c5d9

1 file changed

Lines changed: 12 additions & 3 deletions

File tree

.github/workflows/gh-pages.yml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,18 @@ jobs:
5858
- name: Upload pages artifact
5959
uses: actions/upload-pages-artifact@v4
6060
with:
61-
path: 'book'
61+
path: "book"
6262

6363
- name: Deploy to GitHub Pages
6464
if: github.ref == 'refs/heads/master' && github.event_name == 'push'
65-
id: deployment
66-
uses: actions/deploy-pages@v4
65+
id: github-deployment
66+
uses: actions/deploy-pages@v4
67+
68+
- name: Deploy to Cloudflare Pages
69+
if: github.ref == 'refs/heads/master' && github.event_name == 'push'
70+
id: cloudflare-deployment
71+
uses: cloudflare/wrangler-action@v3
72+
with:
73+
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
74+
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
75+
command: pages deploy book/ --project-name=styxbook --branch=main

0 commit comments

Comments
 (0)