# NixOS containers

6 Hacker News commenters recommended NixOS containers and 0 criticized it, November 2025 to November 2026. It was recommended in 2 of 13 months.

**Verdict:** Recommended as a convenient way to run systemd-nspawn containers from a regular NixOS config. Caveat: they map the entire global Nix store into the container.

## Why people recommend it

- Convenient container setup in NixOS config (2 comments): "NixOS containers are the most convenient way to do this, but those will map the entire global nix store into your container." ([source](https://news.ycombinator.com/item?id=47486594)) "just a few more lines to setup in a regular nixos config" ([source](https://news.ycombinator.com/item?id=47481427))

## What people warn about

- Maps entire global Nix store (1 comments): "NixOS containers are the most convenient way to do this, but those will map the entire global nix store into your container." ([source](https://news.ycombinator.com/item?id=47486594))
- Requires config change, apply, then login (1 comments): "it requires a system config change, apply, and then you need to do container start + machinectl login" ([source](https://news.ycombinator.com/item?id=47485961))

## Alternatives hackers recommend

- [Podman](https://hackerapproved.com/p/podman.md): 276 recommend
- [OrbStack](https://hackerapproved.com/p/orbstack.md): 97 recommend
- [Apple container](https://hackerapproved.com/p/apple-container.md): 56 recommend
- [gVisor](https://hackerapproved.com/p/gvisor.md): 45 recommend
- [Colima](https://hackerapproved.com/p/colima.md): 39 recommend

## Cite as

Hacker Approved, "NixOS containers", https://hackerapproved.com/p/nixos-containers/ (counts from 1,795,640 Hacker News comments, November 2025 to November 2026).
