cj
CDCloudflare Developers
•Created by cj on 10/7/2024 in #workers-help
I'm trying to build ffmpeg.wasm for CF worker. Need help
(Making ffmepg work on a cf worker)
10 replies
CDCloudflare Developers
•Created by cj on 10/7/2024 in #workers-help
I'm trying to build ffmpeg.wasm for CF worker. Need help
Hey @Wallacy
Where you able to give it a try?
10 replies
CDCloudflare Developers
•Created by cj on 10/7/2024 in #workers-help
I'm trying to build ffmpeg.wasm for CF worker. Need help
Awesome! Thank you very much
10 replies
CDCloudflare Developers
•Created by cj on 10/7/2024 in #workers-help
I'm trying to build ffmpeg.wasm for CF worker. Need help
It did set the ENVIRONMENT to WORKER
But it fails here because
self.location
is undefined
This is the error I see in my console
Failed to load FFmpeg: TypeError: Cannot read properties of undefined (reading 'href')Does anyone know how to build ffmpeg for CF Worker? Or building a project using emscripten for CF Worker?
10 replies
CDCloudflare Developers
•Created by cj on 10/7/2024 in #workers-help
I'm trying to build ffmpeg.wasm for CF worker. Need help
Error with emscripten build
But when I tried running my CF worker I get the error
not compiled for this environment (did you build to HTML and try to run it not on the web, or set ENVIRONMENT to something - like node - and run it someplace else - like on the web?)As I understand, this is an emscripten ENV related issue. My environment should be a
SERVICE WORKER
for it to support CF workers
And so I used claude to update my Dockerfile used to build ffmpeg wasm. I added the below code to Dockerfile
But resulting ffmpeg-core.js
still won't work10 replies
CDCloudflare Developers
•Created by cj on 10/7/2024 in #workers-help
I'm trying to build ffmpeg.wasm for CF worker. Need help
Migrating away from web workers
The original ffmpeg.wasm used
web workers
but since CF workers can't create a web worker using new Worker(..)
I've created a single file with the logic from classes.ts and worker.ts
✅ This seems to work.10 replies
CDCloudflare Developers
•Created by Rishabh on 6/6/2024 in #pages-help
Build Failed: build exceeded memory limit and was terminated
You can use CI/CD to build the app and deploy it. This way the deploy is automated
6 replies
CDCloudflare Developers
•Created by Rishabh on 6/6/2024 in #pages-help
Build Failed: build exceeded memory limit and was terminated
You can try deploying from your terminal using
wrangler pages deploy
6 replies
CDCloudflare Developers
•Created by cj on 6/5/2024 in #workers-help
Should `unsafe.bindings.ratelimit` have different `namespace_id` for each worker environment?
Ty. This is much better
3 replies
CDCloudflare Developers
•Created by cj on 6/5/2024 in #workers-help
Should `unsafe.bindings.ratelimit` have different `namespace_id` for each worker environment?
I fixed it
3 replies
CDCloudflare Developers
•Created by cj on 6/4/2024 in #workers-help
Impossible to add a new ENV Variable if using unstable.bindings.RATE_LIMITER
Ty
4 replies