Skip to content

Commit a468cc1

Browse files
committed
Deploy frontend via OpenNext Worker
1 parent 6c63b95 commit a468cc1

6 files changed

Lines changed: 9633 additions & 5405 deletions

File tree

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Deploy Worker
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
paths:
8+
- "frontend/**"
9+
- ".github/workflows/deploy-worker.yml"
10+
workflow_dispatch:
11+
12+
concurrency:
13+
group: deploy-worker-production
14+
cancel-in-progress: true
15+
16+
jobs:
17+
deploy:
18+
runs-on: ubuntu-latest
19+
permissions:
20+
contents: read
21+
defaults:
22+
run:
23+
working-directory: frontend
24+
env:
25+
CLOUDFLARE_ACCOUNT_ID: ${{ vars.CLOUDFLARE_ACCOUNT_ID }}
26+
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
27+
steps:
28+
- uses: actions/checkout@v4
29+
30+
- uses: actions/setup-node@v4
31+
with:
32+
node-version: 22
33+
cache: npm
34+
cache-dependency-path: frontend/package-lock.json
35+
36+
- name: Install dependencies
37+
run: npm ci
38+
39+
- name: Deploy OpenNext Worker
40+
run: npm run deploy:cf

frontend/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515

1616
# next.js
1717
/.next/
18+
/.open-next/
1819
/out/
1920

2021
# production

frontend/open-next.config.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
import { defineCloudflareConfig } from "@opennextjs/cloudflare";
2+
3+
export default defineCloudflareConfig();

0 commit comments

Comments
 (0)