forked from genie-design/sonicjs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
wrangler.example.toml
33 lines (27 loc) · 1.12 KB
/
wrangler.example.toml
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
compatibility_date = "2023-05-18"
name = "sonicjs"
workers_dev = true
main = "src/server.ts"
# Enter your account id
# This can be found at https://dash.cloudflare.com/ --> Workers & Pages
# --> Overview, then in the right sidebar
account_id = "${ACCOUNT_ID}"
# Run the `wrangler kv:namespace create sonicjs` command and copy the id below
# Run the `wrangler kv:namespace create sonicjs --preview` command and copy the preview_id below
# Only update the preview_id and id, leave the binding name as "KVDATA"
kv_namespaces = [
{ binding = "KVDATA", preview_id="${KV_NAMESPACE_PREVIEW_ID}", id = "${KV_NAMESPACE_ID}" }
]
# Run the `wrangler d1 create sonicjs` command and copy the id below
[[d1_databases]]
binding = "D1DATA"
database_name = "sonicjs"
database_id = "${DATABASE_ID}"
# Using Cloudflare R2 (similar to AWS S3) is only necessary if you plan to use SonicJs to manage file assets
# Run the `wrangler r2 bucket create sonicjs` command and uncomment the section below
[[r2_buckets]]
binding = 'R2STORAGE'
bucket_name = 'sonicjs'
vars = { ENVIRONMENT = "production" }
[env.development]
vars = { ENVIRONMENT = "development" }