Cloudflare workers are missing process.env
jakubno opened this issue · comments
Jakub Novák commented
Khalid Zoabi commented
When running on Cloudflare Workers, e2b will likely need to use the env
argument provided to the handler:
export default {
async fetch(request, env, ctx) {
return new Response(`API host: ${env.API_HOST}`);
}
}
A polyfill for this is a better approach (or populating process.env based on the env argument). I'll take a look/stab at it!