-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwrangler.toml
More file actions
30 lines (26 loc) · 1 KB
/
wrangler.toml
File metadata and controls
30 lines (26 loc) · 1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
name = "haste"
main = "src/worker/index.ts"
compatibility_date = "2026-03-20"
compatibility_flags = ["nodejs_compat", "assets_navigation_has_no_effect"]
# Uncomment to use a custom domain
# routes = [
# { pattern = "haste.example.com", custom_domain = true }
# ]
# D1 Database binding
[[d1_databases]]
binding = "DB"
database_name = "haste-db"
database_id = "00000000-0000-0000-0000-000000000000" # Placeholder for local dev - run: wrangler d1 create haste-db for production
# Assets binding for serving static files
[assets]
not_found_handling = "single-page-application"
directory = "./dist/client"
binding = "ASSETS"
# Environment variables
[vars]
MAX_PASTE_SIZE = "400000"
KEY_LENGTH = "10"
DEFAULT_EXPIRE_DAYS = "30"
BROWSER_CACHE_MAX_AGE = "3600" # browser Cache-Control max-age in seconds; "0" to disable
CDN_CACHE_MAX_AGE = "2592000" # CF edge Cloudflare-CDN-Cache-Control max-age in seconds; "0" to disable
CDN_STALE_WHILE_REVALIDATE = "86400" # stale-while-revalidate for CF edge; "0" to omit