Skip to content

Commit

Permalink
Deploy to Cloudflare Workers
Browse files Browse the repository at this point in the history
  • Loading branch information
gxres042 committed Oct 4, 2024
1 parent 88762bf commit bcc4a96
Show file tree
Hide file tree
Showing 4 changed files with 759 additions and 30 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Deploy site

on:
push:
branches:
- main
jobs:
CI:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Prepare pnpm
uses: pnpm/action-setup@v4
with:
version: 9
- name: Prepare Node.js 20
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install dependencies
run: pnpm install
- name: Generate site
run: pnpm build
- name: Deploy to Cloudflare Workers
uses: cloudflare/[email protected]
with:
accountId: ${{ secrets.CF_ACCOUNT_ID }}
apiToken: ${{ secrets.CF_API_TOKEN }}
command: deploy
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@
"typescript": "^5.6.2",
"typescript-eslint": "^8.7.0",
"unocss": "^0.62.4",
"vite": "^5.4.8"
"vite": "^5.4.8",
"wrangler": "^3.79.0"
},
"type": "module",
"dependencies": {
Expand Down
Loading

0 comments on commit bcc4a96

Please sign in to comment.