Skip to content

Commit 5274fdc

Browse files
[Deno Deploy] Update .github/workflows/deploy.yml
1 parent 6f1cebe commit 5274fdc

File tree

1 file changed

+32
-12
lines changed

1 file changed

+32
-12
lines changed

.github/workflows/deploy.yml

+32-12
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,42 @@
1-
name: Deploy to Cloudflare Workers
2-
1+
name: Deploy
32
on:
43
push:
5-
branches:
6-
- main
4+
branches: main
5+
pull_request:
6+
branches: main
77

88
jobs:
99
deploy:
10+
name: Deploy
1011
runs-on: ubuntu-latest
1112

13+
permissions:
14+
id-token: write # Needed for auth with Deno Deploy
15+
contents: read # Needed to clone the repository
16+
1217
steps:
13-
- name: Checkout code
14-
uses: actions/checkout@v2
18+
- name: Clone repository
19+
uses: actions/checkout@v4
20+
21+
- name: Install Deno
22+
uses: denoland/setup-deno@v1
23+
with:
24+
deno-version: v1.x
25+
26+
- name: Install Node.js
27+
uses: actions/setup-node@v4
28+
with:
29+
node-version: lts/*
30+
31+
- name: Install step
32+
run: "npm install"
1533

16-
- name: Install Wrangler
17-
run: npm install -g @cloudflare/wrangler
34+
- name: Build step
35+
run: "NITRO_PRESET=deno-deploy npm run build"
1836

19-
- name: Publish to Cloudflare Workers
20-
run: wrangler publish
21-
env:
22-
CF_API_TOKEN: ${{ secrets.CF_API_TOKEN }}
37+
- name: Upload to Deno Deploy
38+
uses: denoland/deployctl@v1
39+
with:
40+
project: "gusibi-path-meme-web"
41+
entrypoint: "server/index.ts"
42+
root: ".output"

0 commit comments

Comments
 (0)