naporitan
naporitan
CDCloudflare Developers
Created by naporitan on 4/12/2024 in #pages-help
Setting DurableObject from wrangler.toml results in an error.
I found the solution. I needed to add environment = "production".
# Generated by Wrangler on Fri Apr 12 2024 07:46:59 GMT+0900 (Japan Standard Time)
name = "pages"
pages_build_output_dir = ""
compatibility_date = "2024-04-11"


[[durable_objects.bindings]]
name = "SHARE_MESSAGE"
class_name = "ShareMessage"
script_name = "service"
environment = "production"


[env.production]
compatibility_date = "2024-04-11"

[[env.production.durable_objects.bindings]]
name = "SHARE_MESSAGE"
class_name = "ShareMessage"
script_name = "service"
environment = "production"
# Generated by Wrangler on Fri Apr 12 2024 07:46:59 GMT+0900 (Japan Standard Time)
name = "pages"
pages_build_output_dir = ""
compatibility_date = "2024-04-11"


[[durable_objects.bindings]]
name = "SHARE_MESSAGE"
class_name = "ShareMessage"
script_name = "service"
environment = "production"


[env.production]
compatibility_date = "2024-04-11"

[[env.production.durable_objects.bindings]]
name = "SHARE_MESSAGE"
class_name = "ShareMessage"
script_name = "service"
environment = "production"
4 replies