Fixes #94
This commit is contained in:
parent
7d1a04f392
commit
c2ccd2a6a1
@ -46,7 +46,24 @@ export function createSandbox(plug: Plug<any>) {
|
|||||||
workerHref,
|
workerHref,
|
||||||
{
|
{
|
||||||
type: "module",
|
type: "module",
|
||||||
},
|
deno: {
|
||||||
|
permissions: {
|
||||||
|
// Allow network access and servers (main use case: fetch)
|
||||||
|
net: true,
|
||||||
|
// This is required for console loggin to work, apparently?
|
||||||
|
env: true,
|
||||||
|
// No talking to native code
|
||||||
|
ffi: false,
|
||||||
|
// No invocation of shell commands
|
||||||
|
run: false,
|
||||||
|
// No read access to the file system
|
||||||
|
read: false,
|
||||||
|
// No write access to the file system
|
||||||
|
write: false,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
// Have to do this because the "deno" option is not standard and doesn't typecheck yet
|
||||||
|
} as any,
|
||||||
);
|
);
|
||||||
return new Sandbox(plug, new DenoWorkerWrapper(worker));
|
return new Sandbox(plug, new DenoWorkerWrapper(worker));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user