Skip to content

Developer tools · container runtime

systemd-nspawn

Hacker Approved

Recommended for lightweight, systemd-integrated containers that run without a kernel of their own; critics note weak bind mount support and poor image tooling.

Summarized from 34 comments.

Recommended for lightweight, systemd-integrated containers that run without a kernel of their own; critics note weak bind mount support and poor image tooling.

recommend
21
criticize
5
months recommended
8 of 13

Why people love it

  • Easy to set up and spin up · 2

    I've found these to be fairly easy to setup and quite natural if you're already used to the linux ecosystem

    May 2026 · comment

    Systemd-nspawn containers are super easy to spin up

    Jan 2026 · comment
  • Fast, lightweight, no kernel needed · 2

    nspawn containers aren't really any different to regular system images/archives other than they don't need a kernel.

    Jan 2026 · comment

    It ends up being fast and lightweight.

    Sep 2026 · comment
  • Powerful, deeply kernel-aware options · 2

    it has all the options you would ever want, and is actually deeply aware of the kernel capabilities.

    Oct 2026 · comment

    systemd-nspawn can be quite powerful

    Nov 2025 · comment
  • Good for rootless, ephemeral containers · 2

    I find nspawn to be a pretty simple way of doing rootless containers

    Dec 2025 · comment

    I usually just switch to systemd-nspawn --ephemeral containers

    Jul 2026 · comment

What people warn about

  • Weak bind mount support · 3

    Nspawn has a lot of issues with bind mounts in general. They've never been fixed because pottery doesn't see the point.

    Oct 2026 · comment

    I found a bug with nspawn that it can't bind mount while being in the mode which lets you delegate namespaces

    Oct 2026 · comment

    It's annoying you have to edit the config.nspawn to mount a directory

    Jul 2026 · comment

What hackers pick instead

Every quote

The 29 most detailed of 34 comments. Each links to the original.

  1. nspawn containers aren't really any different to regular system images/archives other than they don't need a kernel.

    Mixed · Jan 2026 · in “Lennart Poettering, Christian Brauner founded a new company”

  2. I've found these to be fairly easy to setup and quite natural if you're already used to the linux ecosystem

    Recommends · May 2026 · in “Codex just found a "workaround" of not having sudo on my PC”

  3. it has all the options you would ever want, and is actually deeply aware of the kernel capabilities.

    Recommends · Oct 2026 · in “Show HN: Pi pod – Run your pi coding agent in sandboxes on your own server”

  4. It's annoying you have to edit the config.nspawn to mount a directory

    Mixed · Jul 2026 · in “Show HN: Clawk – Give coding agents a disposable Linux VM, not your laptop”

  5. I find nspawn to be a pretty simple way of doing rootless containers

    Recommends · Dec 2025 · in “Building small Docker images faster”

  6. I usually just switch to systemd-nspawn --ephemeral containers

    Recommends · Jul 2026 · in “Show HN: A lightweight CLI tool to track and purge temporary packages in Linux”

  7. Systemd-nspawn containers are super easy to spin up

    Recommends · Jan 2026 · in “Gentoo Linux 2025 Review”

  8. It ends up being fast and lightweight.

    Mixed · Sep 2026 · in “Show HN: NSL – WSL for Linux”

  9. systemd-nspawn can be quite powerful

    Recommends · Nov 2025 · in “Landlock-Ing Linux”

  10. Nspawn has a lot of issues with bind mounts in general. They've never been fixed because pottery doesn't see the point.

    Criticizes · Oct 2026 · in “A whirlwind tour of systemd-nspawn containers (2025)”

  11. I found a bug with nspawn that it can't bind mount while being in the mode which lets you delegate namespaces

    Criticizes · Oct 2026 · in “A whirlwind tour of systemd-nspawn containers (2025)”

  12. Systemd allows you to make containers via nspawn, which are defined just about the exact same as you do a regular systemd service.

    Recommends · Dec 2025 · in “Systemd v259”

  13. Its nice having the flexibility for both system containers and application containers.

    Recommends · Oct 2026 · in “Docker is weird”

  14. nspawn has to be one the most underrated (and 100% optional ofc) components

    Recommends · Jun 2026 · in “You Don't Love Systemd Timers Enough”

  15. it really makes a wonderful way of running distroless, immutable containers

    Recommends · Nov 2025 · in “Immutable Software Deploys Using ZFS Jails on FreeBSD”

  16. systemd nspawn is actually pretty awesome, though not many people use it.

    Recommends · Jan 2026 · in “The Browser Is the Sandbox”

  17. The surface area is far smaller and they're way easier to inspect.

    Recommends · Jul 2026 · in “Ditching Vagrant: VMs with KVM and Virsh on Debian”

  18. The combination feels quite powerful if you are in the ecosystem.

    Recommends · Oct 2026 · in “A whirlwind tour of systemd-nspawn containers (2025)”

  19. if that's your preference https://nspawn.org is just right.

    Recommends · Sep 2026 · in “Show HN: NSL – WSL for Linux”

  20. systemd-nspawn being a hidden gem for this usecase

    Recommends · Nov 2025 · in “Immutable Software Deploys Using ZFS Jails on FreeBSD”

  21. It uses systemd-nspawn, and it's great.

    Recommends · Jan 2026 · in “Using Proxies to Hide Secrets from Claude Code”

  22. I already use nspawn for containers

    Recommends · Jul 2026 · in “Ditching Vagrant: VMs with KVM and Virsh on Debian”

  23. nspawn feels like a natural choice

    Recommends · Oct 2026 · in “Docker is weird”

  24. This is a replacement for docker.

    Recommends · May 2026 · in “Codex just found a "workaround" of not having sudo on my PC”

  25. it does look pretty danged neat

    Recommends · Jul 2026 · in “Ditching Vagrant: VMs with KVM and Virsh on Debian”

  26. it was basically ready to go

    Recommends · Oct 2026 · in “Docker is weird”

  27. The problem is that the tooling for creating, importing, and managing images is not as good with systemd

    Criticizes · May 2026 · in “Codex just found a "workaround" of not having sudo on my PC”

  28. I think I and lot of others lack a clear instruction how to use it

    Criticizes · Oct 2026 · in “Show HN: Pi pod – Run your pi coding agent in sandboxes on your own server”

  29. doesn't provide separation from the host like podman does

    Criticizes · Oct 2026 · in “A whirlwind tour of systemd-nspawn containers (2025)”

Counts from 1,795,640 Hacker News comments, Nov 2025 to Nov 2026. How we count · Report a mistake