wrangler deploy returns workers.api.error.route_not_allowed_on_subdomain

112 views Asked by At

We have a worker that redirects some paths to a newer codebase. We've been adding those routes manually in the Cloudflare UI (and it works), but we'd like to save those paths in wrangler.toml for version control. I've added the routes to wrangler.toml like:

routes = [
  { pattern = "www.example.com/ko/lists/*", zone_name = "example.com"},
...
  { pattern = "www.example.com/lists/*", zone_name = "example.com"}
]

When we run wrangler deploy, we see this error message: workers.api.error.route_not_allowed_on_subdomain [code: 10038]

The routes include www when we add them in the UI, so I don't think that's the problem. Any ideas?

0

There are 0 answers