binding and variables conflicting in env

Hi, I have a problem with the "env" in a worker. This worker uses another worker as a service and contains a variable. The wrangler.toml looks like this: [vars] URL = "https://geturlforexample.com/v1/token/" services = [ { binding = "GET_ID", service = "getcustomerid" } ] The problem is that if I remove the variable and leave only the service then the binding works, but if I leave the variable this seems to interfere with the binding and the worker fails. Is there a bug somewhere around this or perhaps a way to add the variable that does not interfere with the binding? thanks!
2 Replies
kian
kian7mo ago
[vars]
URL = "https://geturlforexample.com/v1/token/"

[[services]]
binding = "GET_ID"
service = "getcustomerid"
[vars]
URL = "https://geturlforexample.com/v1/token/"

[[services]]
binding = "GET_ID"
service = "getcustomerid"
services = [
{ binding = "GET_ID", service = "getcustomerid" }
]

[vars]
URL = "https://geturlforexample.com/v1/token/"
services = [
{ binding = "GET_ID", service = "getcustomerid" }
]

[vars]
URL = "https://geturlforexample.com/v1/token/"
either will work
yoav8888
yoav8888OP7mo ago
thanks! works great!
Want results from more Discord servers?
Add your server