Repository navigation
Expand file tree
/
Copy pathwrangler.jsonc
More file actions
85 lines (85 loc) · 3.59 KB
/
Copy pathwrangler.jsonc
File metadata and controls
85 lines (85 loc) · 3.59 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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
{
"name": "dualmind-arena",
"main": "worker.js",
"compatibility_date": "2024-12-01",
"workers_dev": true,
"routes": [
{
"pattern": "arena.dualmindlab.tech/*",
"zone_name": "dualmindlab.tech"
}
],
"assets": {
"directory": "dist",
"binding": "ASSETS",
// Every request runs worker.js first, so the pre-launch redirect (FORCE_WAITLIST in
// worker.js) also covers paths that match a static file, such as / and /leaderboard/.
"run_worker_first": true
},
"vars": {
// The public Supabase project URL (also in the web app's build config). The v2 router
// verifies access tokens against ${SUPABASE_URL}/auth/v1/.well-known/jwks.json. Secrets
// (SUPABASE_JWT_SECRET, PRIVACY_SALT) are optional and are not set here.
"SUPABASE_URL": "https://calqfzajyidkdzbaswjp.supabase.co"
},
"flagship": [
{
"binding": "FLAGS",
"app_id": "1b260a52-d2dd-4116-a42e-43c9e71fe717"
}
],
// Backend add-ons (ADR 0007, docs/backend/resources.md). Each resource has a production and a
// preview copy. Workers Builds previews share one config with production, so code picks the
// production binding only when the request host is arena.dualmindlab.tech and the *_PREVIEW
// binding everywhere else (previews, local runs, tests). Nothing uses these bindings yet; a
// route whose binding is missing answers 501 not_enabled.
"d1_databases": [
{
"binding": "DB",
"database_name": "dualmind-arena-ledger",
"database_id": "19fc71bd-1236-4f5e-af29-c618bc58e2e6",
"migrations_dir": "server/migrations"
},
{
"binding": "DB_PREVIEW",
"database_name": "dualmind-arena-ledger-preview",
"database_id": "f2f963c9-1ed6-499e-b11e-285897228b89",
"migrations_dir": "server/migrations"
}
],
"kv_namespaces": [
{ "binding": "CACHE", "id": "7906c64bd2ce42ed987eab78490d5ee4" },
{ "binding": "CACHE_PREVIEW", "id": "915a45a0464a4ea982b9740c9aae03ec" }
],
"queues": {
// Producers only for now; consumers (with their dead-letter queues arena-events-dlq and
// arena-events-preview-dlq) are added together with the queue() handler.
"producers": [
{ "binding": "EVENTS", "queue": "arena-events" },
{ "binding": "EVENTS_PREVIEW", "queue": "arena-events-preview" }
]
},
"r2_buckets": [
{ "binding": "PUBLIC_BUCKET", "bucket_name": "dualmind-arena-public" },
{ "binding": "PUBLIC_BUCKET_PREVIEW", "bucket_name": "dualmind-arena-public-preview" }
],
// Rate limits (BE-3, server/rate-limit.js). The Workers Rate Limiting binding needs no account
// resource, only a namespace_id: account-wide positive integers chosen here, so do not reuse
// 1001 to 1005 in other Workers. period is 10 or 60 seconds. The numbers here must equal
// RATE_LIMIT_GROUPS in server/rate-limit.js (a test fails when they differ). Counting is
// approximate and per Cloudflare location. Kill switch: remove an entry (that group then
// fails open) or raise its limit. PRIVACY_SALT (optional secret) makes anonymous keys HMACs.
"ratelimits": [
{ "name": "RL_BATTLE", "namespace_id": "1001", "simple": { "limit": 6, "period": 60 } },
{ "name": "RL_VOTE", "namespace_id": "1002", "simple": { "limit": 10, "period": 10 } },
{ "name": "RL_SPEECH", "namespace_id": "1003", "simple": { "limit": 10, "period": 60 } },
{ "name": "RL_WRITE", "namespace_id": "1004", "simple": { "limit": 30, "period": 60 } },
{ "name": "RL_READ", "namespace_id": "1005", "simple": { "limit": 30, "period": 10 } }
],
"observability": {
"logs": {
"enabled": false,
"invocation_logs": true
}
}
}