Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Deno 6 min read Deep dive easyNovice

The Anatomy of an Isolate Cloud

Deno Deploy runs untrusted user JavaScript in V8 isolates rather than VMs or containers, trading heavier isolation for much lower overhead and faster deploys. Traffic reaches 30+ edge locations via anycast, where a Rust runner process acts as an isolate hypervisor: it maps the Host/:authority header to a deployment, picks a TLS certificate via SNI, starts deployment processes on demand and terminates idle ones. Security is layered across a restricted custom Deno build, V8 sandboxing, one process per deployment, resource quotas enforced by the runner, separated control- and data-plane networks, seccomp syscall filtering, and Rust's memory safety.

Related posts

  • How we built a secure, performant, multi-tenant cloud platform to run untrusted code

    Deno mediumAdept

    Deno Deploy runs untrusted JavaScript and TypeScript in pools of V8 isolates inside VMs called runners, split into a control plane for deployments and a data plane of edge regions. At deploy time, code is transpiled with swc, all dependencies are vendored and ordered breadth-first so they can be streamed into V8, and the bundle is replicated to regional buckets. Postgres stays off the critical path, and edge proxies keep an in-memory domain-to-deployment table. Requests arrive via Anycast, and the proxy picks a runner using heuristics over CPU and memory load. Isolation combines namespaces, cgroups, seccomp and a watchdog process, built against a five-point tenant threat model.

  • How security and tenant isolation allows Deno Subhosting to run untrusted code securely

    Deno easyNovice

    Deno Deploy and Deno Subhosting isolate untrusted tenant code using layered defenses mapped to a five-point threat model: per-deployment V8 isolates, a virtualized filesystem, and separate VPCs for ingress and outbound traffic. Each isolate runs in its own process on a restricted Deno runtime, inside Linux namespaces, with seccomp filters to detect unusual syscalls. For resource fairness, cgroups cap CPU, memory and I/O, and an internal WatchDog service kills isolates that exceed memory limits, block the event loop, or show abusive patterns such as crypto mining. The mechanisms are described at a high level, without configuration or implementation specifics.

  • Introducing Deno Sandbox

    Deno mediumAdept

    Deno Sandbox runs untrusted, often LLM-generated code in lightweight Linux microVMs on Deno Deploy that boot in under a second and are created via JavaScript or Python SDKs. Secrets never enter the VM: code sees a placeholder that an outbound proxy swaps for the real key only on requests to approved hosts, and egress allowlists block unlisted hosts at the VM boundary. Sandboxes can deploy straight to Deno Deploy with sandbox.deploy(), persist state with volumes and snapshots, and run with 2 vCPUs, 768 MB to 4 GB of memory and a 30-minute maximum lifetime. A later update says the product is no longer offered to new customers after Deno joined Cloudflare.

  • How immutable scripts in Deno allow Windmill.dev (YC S22) to build production-grade ops

    Deno easyNovice

    Windmill.dev, an open-source platform for building internal workflows and UIs from scripts, runs TypeScript on Deno because inline, version-pinned imports make each script a self-contained, reproducible file that is hashed immutably and stored in Postgres. Deno's opt-in permission model isolates untrusted code in a multi-tenant setting with less overhead than the NSJail sandboxing used for other languages. Dependency caching synced across workers via S3 gives roughly 15ms cold starts and about 30ms end-to-end runs for lightweight scripts, and the team plans to run Deno in-process to approach Lambda-level performance.

  • Deno 1.20 Release Notes

    Deno mediumAdept

    Deno 1.20 cuts JavaScript-to-Rust op call overhead by up to ~60% by using Rust proc macros to generate a dedicated V8 binding per op, eliminating op routing and skipping deserialization of unused arguments; a 1 MB base64 roundtrip drops from ~125 ms to ~3.3 ms. The release also adds automatic gzip/brotli compression of non-streamed HTTP responses, an unstable `deno bench` subcommand (1000 warmup plus 1000 measured iterations by default), and a cross-platform `deno task` runner using a POSIX-like shell subset. Other changes include import maps in the config file, in-memory TLS certs, `Deno.upgradeHttp()`, FFI global statics, opt-in `--trace-ops` for test leak tracing (made opt-in because of a performance regression), `AbortSignal.timeout()`, and stricter default permissions for tests and workers, plus TypeScript 4.6 and V8 10.0.

The quest for software engineering knowledge.

Look:
Layout: