This repository has been archived on 2026-06-09. You can view files and clone it, but cannot push or open issues or pull requests.
wedding-app/apps/web/wrangler.toml
Claude 11167e48f3
refactor: migrate web app to Workers + Static Assets format
The Cloudflare project was created as a Workers Build (the new
unified format), so the legacy Pages config (pages_build_output_dir,
functions/api/[[path]].ts) does not deploy. Switch to the modern
shape: a worker entry point that delegates to the Hono app for
/api/* and falls through to the [assets] binding for everything
else, with SPA fallback for client-side routes.

Build output (apps/web/dist) and bindings (D1, R2, env vars) are
unchanged.

https://claude.ai/code/session_01TPBqgcSJMppgrpiq7fLywL
2026-05-04 00:57:28 +00:00

36 lines
926 B
TOML

name = "stefanieeleandro"
main = "src/worker.ts"
compatibility_date = "2026-04-01"
compatibility_flags = ["nodejs_compat"]
[assets]
directory = "./dist"
binding = "ASSETS"
not_found_handling = "single-page-application"
run_worker_first = ["/api/*"]
[[d1_databases]]
binding = "DB"
database_name = "wedding-db"
database_id = "81fac13f-00b2-49ec-b7df-bde036849e70"
migrations_dir = "../api/migrations"
[[r2_buckets]]
binding = "MEDIA"
bucket_name = "wedding-media"
[vars]
COUPLE_NAMES = "Stefanie & Leandro"
PUBLIC_BASE_URL = "https://stefanieeleandro.pages.dev"
S3_REGION = "auto"
S3_BUCKET = "wedding-media"
S3_FORCE_PATH_STYLE = "false"
# S3_ENDPOINT, S3_PUBLIC_BASE_URL, CF_ACCESS_TEAM, CF_ACCESS_AUD are
# set after Cloudflare config (see deploy notes).
#
# Secrets (set via `wrangler secret put <NAME>` or via the dashboard):
# S3_ACCESS_KEY_ID
# S3_SECRET_ACCESS_KEY
# TURNSTILE_SECRET
# ALLOWED_ADMIN_EMAILS