Distrobox is the single piece of software that completely changed the way I work. If you’ve hear of or used Vagrant and thought it was a great idea but implemented in a really heavy handed manner, then Distrobox is exactly what you’ve been looking for.
Within a month Distrobox became my primary dev ...
This is a neat write up, but I'm curious what gaming inside a Distrobox container would be like. For starters, is there any performance impact or potential glitches like screen tearing, and second, could I say, install a more recent mesa package in the container (assuming this is Fedora Silverblue), and have the game use it?
My issue with flatpaks is that having too many flatpaks becomes a chore to manage. I did not have a fun time with Steam in a flatpak (required some mucking around to get the DPI and cursor size right) and same with Chromium a while back (took me a long time to figure out how to pass on the flags to enable Wayland support). IMO, having a single container (or a container for a particular activity, like gaming) would be a much more cleaner approach, while offering the flexibility akin to a mutable OS (so no weird flatpak quirks to deal with.. in theory). This would also make things like backups easier, I could just save my "gaming" container to one tar and not worry about whether I missed any dependencies etc.
I think so but this method does remove the quite significant barrier of having to figure out nix's language and quirks, so I'd argue there's merit to the workflow. Still, you're trading it for containerization know-how, so not necessarily the best choice.
Yeah it does. I actually use nix as my base OS on one machine. But when I need to work on a project that will never be packaged with nix, and I need all the dependencies, it really becomes impossible to just use nix.
I don't really get the comparison to vagrant. It doesn't seem like it feels the same role? Can distro box be used to share environments with other developers or used in CI/CD processes?
I use it to share environments with a small team. Just have distrobox specific Docker files and we can all spin up the same distrobox environment locally.
We end up having a different base docker file (e.g. our distrobox one has editors and stuff), but we all share the same project specific docker file. That same project specific file gets used in CI/CD and deployment, but with a minimal base. So all in all, I would say it's even better than Vagrant because we run the same system in production.