Files
oh-my-opencode/.github/workflows/web-deploy.yml
T
YeonGyu-Kim 7fe197d8f1 chore(workflows): trigger web-deploy on dev push too
PRs land on `dev` (master is blocked by `block-master-pr`), but the
deploy workflow only listened to `master` pushes — so #3853's web/
dependency bumps merged to dev with no Cloudflare deployment ever
running.

Add `dev` to the push branches list. The existing `paths` filter
keeps the deploy from firing on non-web changes, and `workflow_dispatch`
is preserved as the manual fallback.
2026-05-08 14:57:58 +09:00

56 lines
1.4 KiB
YAML

name: Web Deploy (Cloudflare Workers)
on:
workflow_dispatch:
inputs:
environment:
description: "Wrangler environment (leave blank for default)"
required: false
default: ""
push:
branches: [master, dev]
paths:
- "web/**"
- ".github/workflows/web-deploy.yml"
concurrency:
group: web-deploy-${{ github.ref }}
cancel-in-progress: false
jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: web-production
url: https://ohmyopenagent.com
defaults:
run:
working-directory: web
permissions:
contents: read
deployments: write
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
with:
bun-version: "1.3.12"
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Build with OpenNext for Cloudflare
run: |
bun run prebuild
bunx opennextjs-cloudflare build
env:
NEXT_TELEMETRY_DISABLED: "1"
- name: Deploy to Cloudflare Workers
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
workingDirectory: web
command: ${{ inputs.environment && format('deploy --env {0}', inputs.environment) || 'deploy' }}