75 lines · 2.9 KBRaw
| 1 | { |
| 2 | "$schema": "./node_modules/wrangler/config-schema.json", |
| 3 | "name": "refs", |
| 4 | "main": "./workers/main.ts", |
| 5 | "compatibility_date": "2026-10-02", |
| 6 | "routes": [{ "pattern": "useref.dev", "custom_domain": true }], |
| 7 | "artifacts": [ |
| 8 | { "binding": "ARTIFACTS", "namespace": "refs", "remote": true } |
| 9 | ], |
| 10 | "d1_databases": [ |
| 11 | { "binding": "DB", "database_name": "refs", "migrations_dir": "migrations" } |
| 12 | ], |
| 13 | "kv_namespaces": [{ "binding": "OAUTH_KV" }], |
| 14 | "durable_objects": { |
| 15 | "bindings": [ |
| 16 | { "name": "USER_HUB", "class_name": "UserHub" }, |
| 17 | { "name": "REPO_HUB", "class_name": "RepoHub" }, |
| 18 | { "name": "RUN_HUB", "class_name": "RunHub" }, |
| 19 | { "name": "JOB_RUNNER", "class_name": "JobRunner" }, |
| 20 | { "name": "JOB_SLOTS", "class_name": "JobSlots" } |
| 21 | ] |
| 22 | }, |
| 23 | "queues": { |
| 24 | "producers": [ |
| 25 | { "binding": "PUSHES", "queue": "refs-pushes" }, |
| 26 | { "binding": "AGENT_RUNS", "queue": "refs-agent-runs" } |
| 27 | ], |
| 28 | "consumers": [ |
| 29 | { "queue": "refs-pushes", "max_retries": 8, "dead_letter_queue": "refs-pushes-dlq" }, |
| 30 | { "queue": "refs-pushes-dlq" }, |
| 31 | { "queue": "refs-agent-runs", "max_batch_size": 1, "max_retries": 1, "dead_letter_queue": "refs-agent-runs-dlq" }, |
| 32 | { "queue": "refs-agent-runs-dlq" } |
| 33 | ] |
| 34 | }, |
| 35 | "triggers": { "crons": ["*/5 * * * *"] }, |
| 36 | "migrations": [ |
| 37 | { "tag": "v1", "new_sqlite_classes": ["TaskHub"] }, |
| 38 | { "tag": "v2", "renamed_classes": [{ "from": "TaskHub", "to": "RepoHub" }] }, |
| 39 | { "tag": "v3", "deleted_classes": ["RepoHub"] }, |
| 40 | { "tag": "v4", "new_sqlite_classes": ["UserHub"] }, |
| 41 | { "tag": "v5", "new_sqlite_classes": ["RepoHub"] }, |
| 42 | { "tag": "v6", "new_sqlite_classes": ["RunHub", "JobRunner", "JobSlots"] } |
| 43 | ], |
| 44 | "containers": [ |
| 45 | { |
| 46 | "name": "refs-jobs", |
| 47 | "class_name": "JobRunner", |
| 48 | "scheduling_policy": "durable_object", |
| 49 | "images": { |
| 50 | "base": { "dockerfile": "./workers/images/base/Dockerfile" }, |
| 51 | "node": { "dockerfile": "./workers/images/node/Dockerfile" }, |
| 52 | "python": { "dockerfile": "./workers/images/python/Dockerfile" }, |
| 53 | "go": { "dockerfile": "./workers/images/go/Dockerfile" }, |
| 54 | "rust": { "dockerfile": "./workers/images/rust/Dockerfile" }, |
| 55 | "android": { "dockerfile": "./workers/images/android/Dockerfile" } |
| 56 | } |
| 57 | } |
| 58 | ], |
| 59 | "workflows": [{ "name": "refs-runs", "binding": "RUNS", "class_name": "RunPipeline" }], |
| 60 | "dev": { "enable_containers": false }, |
| 61 | "ratelimits": [ |
| 62 | { "name": "LOGIN_LIMITER", "namespace_id": "1001", "simple": { "limit": 10, "period": 60 } } |
| 63 | ], |
| 64 | "vars": { |
| 65 | "ADMIN_EMAILS": "thisisamank@gmail.com", |
| 66 | "EMAIL_FROM": "noreply@useref.dev", |
| 67 | "PUBLIC_ORIGIN": "https://useref.dev", |
| 68 | "POSTHOG_ENABLED": "false", |
| 69 | "POSTHOG_PROJECT_TOKEN": "phc_oZkCWi9oE6HHRws4mWbKouSaeu2N4xoxVnkARLYofmxu", |
| 70 | "POSTHOG_HOST": "https://us.i.posthog.com" |
| 71 | }, |
| 72 | "ai": { "binding": "AI", "remote": true }, |
| 73 | "send_email": [{ "name": "EMAIL" }], |
| 74 | "observability": { "enabled": true } |
| 75 | } |