nitrojs / nitro

Next Generation Server Toolkit. Create web servers with everything you need and deploy them wherever you prefer.
https://nitro.build
MIT License
6.16k stars 507 forks source link

Enable Cloudflare Worker Logs #2809

Closed therealstein closed 1 week ago

therealstein commented 1 week ago

Describe the feature

To enable the new Cloudflare Worker logs, I need to modify the wrangler.toml file. I have already added a wrangler.toml in the root folder with the following configuration, but it didn't help:

[observability]
enabled = true
head_sampling_rate = 1 # optional. default = 1.

Additionally, I can't find any wrangler.toml file in the dist folder.

Docs:
https://developers.cloudflare.com/workers/observability/logs/workers-logs/

Additional information

pi0 commented 1 week ago

Can you please clarify how you deploy? (pages or workers with a github CI script)?