shiichan

Local Containers dev just got automatic FUSE support!

Hi, it's Shii! While checking Cloudflare's Changelog today, I found some news that makes local development a lot smoother. It might look like a small thing, but it's a nice update if you work with Containers, so let me walk you through it!

Cloudflare Changelog developers.cloudflare.com

What was announced?

According to Cloudflare's Changelog, Miniflare now automatically grants local Containers the Docker privileges required for Filesystem in Userspace (FUSE). This applies across the board: wrangler dev, the Cloudflare Vite plugin, and direct Miniflare use.

FUSE is a mechanism that lets you build a filesystem in user space, and at Cloudflare it's used for things like mounting an R2 bucket inside a container.

The story so far

Until now, how you'd get FUSE working against your local Docker setup varied by environment, and it was something you had to think about yourself. With this update, Miniflare checks the state of your Docker daemon and automatically decides whether to grant the privileges when the conditions are met.

What changes

Containers that rely on FUSE (for example, ones that mount an R2 bucket as a filesystem) become much easier to run locally with wrangler dev. You don't need to manually tweak Docker permissions yourself; as long as your setup meets the conditions, Miniflare takes care of it, which should make the development loop for Containers smoother.

Dive Deep

Whether the privileges get granted automatically depends on your environment. Here's the breakdown!

Supported environments:

  • Docker engine on macOS (when the Docker daemon runs inside a VM)
  • Docker via Windows Subsystem for Linux (WSL) (also VM-based)
  • Rootless Docker on Linux (when /dev/fuse is available)

Not supported:

  • Rootful Docker on Linux (it doesn't support FUSE by default during local development)
  • Cases where the conditions above aren't met, or the Docker daemon's state can't be inspected

So Miniflare inspects the state of the Docker daemon and only hands over FUSE privileges when the conditions are satisfied, a safety-first design. For the detailed requirements and troubleshooting, check "FUSE support during local development," and for a working example of mounting an R2 bucket with FUSE, there's "Mount R2 buckets with FUSE" — worth a look if you want to try this out.

Wrap-up

  • Miniflare now automatically grants local Containers the Docker privileges needed for FUSE
  • It covers wrangler dev, the Cloudflare Vite plugin, and direct Miniflare use
  • Supported on macOS, WSL, and rootless Docker on Linux (with /dev/fuse available); rootful Docker on Linux is not supported
  • A nice update if you're a developer who wants to try FUSE-based Containers, like mounting R2 buckets, locally