Skip to content

Commit c4029cc

Browse files
committed
ci: deploy to worker
1 parent 33486c8 commit c4029cc

2 files changed

Lines changed: 31 additions & 1 deletion

File tree

.github/workflows/deploy.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Deploy Production
2+
on:
3+
push:
4+
branches:
5+
- main
6+
7+
jobs:
8+
deploy:
9+
runs-on: ubuntu-latest
10+
name: Deploy
11+
permissions:
12+
pull-requests: write
13+
steps:
14+
- uses: actions/checkout@v4
15+
- uses: pnpm/action-setup@v4
16+
with:
17+
version: 10
18+
- name: Install Dependencies
19+
run: pnpm install
20+
- name: Build
21+
run: pnpm build
22+
- name: Deploy
23+
id: deploy
24+
uses: cloudflare/wrangler-action@v3
25+
with:
26+
packageManager: pnpm
27+
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
28+
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
29+
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
30+
command: deploy --assets ./dist --name compio-website-2 --latest --domain ww2.compio.rs

.github/workflows/preview.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
2525
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
2626
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
27-
command: pages deploy ./dist --project-name=compio-website
27+
command: versions upload --assets ./dist --name compio-website-2 --latest
2828
- name: Comment PR
2929
uses: thollander/actions-comment-pull-request@v3
3030
with:

0 commit comments

Comments
 (0)