NixOS: Running Foreign Apps via Distrobox
Sometimes an app on NixOS is only available for Ubuntu/Debian or ships as .deb/.iso. Distrobox lets you run it in a container with host integration - like a native app. 💡 Works on any distro with Nix installed. 📦 Create container # Create container with necessary volume mounts nix shell nixpkgs#distrobox --command distrobox create \ --image ubuntu:20.04 \ --name <container-name> \ --volume "<volume_pts>:/dev/pts" \ --volume "<volume_journal>:/var/log/journal" \ --home "$HOME/<container-name>-home" Parameters: --image - base image (ubuntu:20.04, debian:11, etc.) --volume - mount directories (audio, logs) --home - separate home directory inside container --name - container name (used in other commands) Enter container: ...