File tree Expand file tree Collapse file tree 1 file changed +62
-0
lines changed Expand file tree Collapse file tree 1 file changed +62
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CI
2+ on :
3+ push :
4+ branches : [main]
5+ tags :
6+ - " [0-9]+.[0-9]+.[0-9]+"
7+ pull_request :
8+ branches : [main]
9+ permissions :
10+ contents : read
11+ jobs :
12+ audit :
13+ name : Audit
14+ runs-on : ubuntu-latest
15+ steps :
16+ - uses : actions/checkout@v4
17+ - uses : actions/setup-node@v4
18+ with :
19+ node-version : 22
20+ cache : ' npm'
21+ - name : Install Dependencies
22+ run : npm ci
23+ - name : Run Audit
24+ run : npm audit --omit=dev --audit-level=moderate
25+ verify :
26+ name : Verify
27+ runs-on : ubuntu-latest
28+ needs : [audit]
29+ steps :
30+ - uses : actions/checkout@v4
31+ - uses : actions/setup-node@v4
32+ with :
33+ node-version : 22
34+ cache : ' npm'
35+ - name : Install Dependencies
36+ run : npm ci
37+ - name : Run Lint
38+ run : npm run lint
39+ - name : Run Types
40+ run : npm run types
41+ - name : Validate Wrangler Config
42+ run : test -f wrangler.toml
43+ - name : Dry run deploy
44+ run : npx wrangler deploy --dry-run
45+ deploy :
46+ name : Deploy
47+ runs-on : ubuntu-latest
48+ needs : [verify]
49+ if : startsWith(github.ref, 'refs/tags/')
50+ steps :
51+ - name : Checkout code
52+ uses : actions/checkout@v4
53+ - uses : actions/setup-node@v4
54+ with :
55+ node-version : 22
56+ cache : ' npm'
57+ - name : Install dependencies
58+ run : npm ci
59+ - name : Deploy to Cloudflare Workers
60+ run : npx wrangler deploy
61+ env :
62+ CLOUDFLARE_API_TOKEN : ${{ secrets.TRIFROST_CLOUDFLARE_CI }}
You can’t perform that action at this time.
0 commit comments