Cloudflare Developers

CD

Cloudflare Developers

Welcome to the official Cloudflare Developers server. Here you can ask for help and stay updated with the latest news

Join

What exactly are they hoping to do CF

What exactly are they hoping to do? CF-Worker is per-Worker but if theyā€™re just looking to whitelist Workers in general then itā€™ll be IP ranges or ASN.

If you add `AS13335` to your whitelist

If you add AS13335 to your whitelist, it should allow all Cloudflare IPs through your firewall automatically.

It would need to be done on L7 as the

It would need to be done on L7 as the only way to identify a Worker uniquely is the CF-Worker request header

CF Worker Stripe - Error No signatures found matching the expected signature for payload.

It's wayyy easier in Wrangler 2! I have a blog post for verifying Stripe Webhook Signatures at https://jross.me/verifying-stripe-webhook-signatures-cloudflare-workers/. You can ignore the parts after "Setup" if you just want to get Stripe working with wrangler2 šŸ˜„

Real data in local mode

Hey everyone! We've recently been thinking about using real production KV/R2 data in local mode with wrangler dev --local and Miniflare. This suggestion was raised a while ago by @Erwin (https://github.com/cloudflare/miniflare/issues/24), but it would be great to get feedback from you all on this idea. How do you think this should work? Would you prefer if we always fetched/wrote from/to your actual KV namespaces/R2 buckets to give you the most up-to-date values? Or would you prefer the lower-latency of fetching values once then caching them locally? Would you be ok if we just fetched all of your data in one go, and then you just developed as if it were local, or have you got too many keys/objects for that?...

503 issue

it's a proxied worker

Property 'default' does not exist on type 'CacheStorage'

I am seeing a typescript error for let response = await caches.default.match(req); which shows Property 'default' does not exist on type 'CacheStorage'. ts(2339) It seems to be using the CacheStorage definition from /node_modules/typescript/lib/lib.dom.d.ts instead of @cloudflare/workers-types...

Cache API questions

yeah sorry should have been clearer

Here s a quick snippet for you that

Here's a quick snippet for you that should work: ```ts export default { async fetch(request: Request) { if (new URL(request).pathname === '/app') {...

Generally speaking if you re looking at

Generally speaking if you're looking at firebase and all that I don't think it matters much if you just use postgres like a nosql database aha. I doubt the scale you'd be looking at would be enough to suitable strain postgres before something like firebase would be unrealistically expensive aha. However, you can self host supabase with something like yugabyte db which can support fat rows....

can you screenshot your cloudflare

can you screenshot your cloudflare dashboard nav showing d1 then I can add you to the channel šŸ™‚

In workers I can access D1 when I deploy

In workers. I can access D1 when I deploy using a separate worker, but not in the Remix loader. Also I cannot access D1 when local testing with miniflare.

Hydration problem

So are you partially Server-Side Rendering a Client-Side Framework? That sounds like you are over complicating thingsā€¦

Probably your package json or are you

Probably your package.json - or are you using an old wrangler version which had webpack built in? If you can share your project or the package.json, that would be helpful

I want to create a worker that

I want to create a worker that dynamically generates and returns a barcode as an image (so I can embed a link directly to the worker which will generate the barcode on the fly). I've managed to work up a proof-of-concept in Pipedream using bwipjs - I don't think it's supported on CF Workers though. Anybody have any ideas?...

I m confused it seems to be possible to

I'm confused, it seems to be possible to either purge by key locally or purge all assets globally. Is it possible to purge by key globally?

Otto's Issue

The worker is now just returning the text "internal"

I dont understand what you are trying to

I dont understand what you are trying to say šŸ¤” as in you currently dont use workers but you want to switch over to workers without the site going down?

What does Worker is not completely set

What does "Worker is not completely set up" usually mean? It appears that my worker is ready on the dashboard (it looks the same as all my other workers šŸ¤·ā€ā™‚ļø )
No description

Rust-WASM & Async

Async is supported fine, it's just on the JavaScript runtime