Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .cursor/worktrees.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"setup-worktree": [
"bun install"
]
}
16 changes: 4 additions & 12 deletions .github/workflows/docs-build-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,11 @@ jobs:
with:
submodules: true

- name: Enable Corepack
run: corepack enable

- name: Pin Yarn 4.9.1
run: corepack prepare yarn@4.9.1 --activate

- name: Use Node.js 20.x
uses: actions/setup-node@v4
with:
node-version: 20.18.1
- name: Install Bun
uses: oven-sh/setup-bun@v2

- name: Install dependencies
run: yarn install --immutable
run: bun install --frozen-lockfile

- name: Build
run: yarn build
run: bun run build
45 changes: 23 additions & 22 deletions .github/workflows/docs-deploy-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

name: Deploy Docs to Production

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

on:
push:
branches:
Expand Down Expand Up @@ -36,31 +40,16 @@ jobs:
with:
submodules: true

- name: Install Bun
uses: oven-sh/setup-bun@v2

- name: Use Node.js 20.x
uses: actions/setup-node@v4
with:
node-version: 20.18.1

- name: Enable Corepack
run: corepack enable

- name: Install dependencies
run: yarn install

- name: Create GitHub Deployment
id: create_deployment
uses: chrnorm/deployment-action@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
environment: production
ref: ${{ github.sha }}

- name: Mark deployment in progress
uses: chrnorm/deployment-status@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
deployment-id: ${{ steps.create_deployment.outputs.deployment_id }}
state: in_progress
run: bun install --frozen-lockfile

- name: Generate production env file
run: |
Expand Down Expand Up @@ -104,13 +93,25 @@ jobs:
}
EOF

- name: Build OpenNext (no deployment)
run: |
set -e
bun run build:prep
bunx opennextjs-cloudflare build --config wrangler.jsonc

- name: Create GitHub Deployment
id: create_deployment
uses: chrnorm/deployment-action@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
environment: production
ref: ${{ github.sha }}

- name: Deploy to Cloudflare Workers (Production)
id: deploy
run: |
set -e
yarn build:prep
yarn opennextjs-cloudflare build --config wrangler.jsonc
OUTPUT=$(yarn opennextjs-cloudflare deploy --config wrangler.jsonc)
OUTPUT=$(bunx opennextjs-cloudflare deploy --config wrangler.jsonc)
echo "$OUTPUT"
# Extract deployment URL if available
DEPLOYMENT_URL=$(echo "$OUTPUT" | grep -oE 'https://[^ ]+' | head -1)
Expand Down
Loading