What does HackerNews think of distrobox?

Use any linux distribution inside your terminal. Enable both backward and forward compatibility with software and freedom to use whatever distribution you’re more comfortable with. Mirror available at: https://gitlab.com/89luca89/distrobox

Language: Shell

#6 in Bash
#16 in Docker
#18 in Linux
#2 in Ubuntu
I use NixOS as a daily driver. (My previous Linux of choice had been Arch).

I'd describe Nix as 95% wonderful, 5% hugely painful.

I learned Nix by using it on macOS/Linux before trying NixOS. I was concerned that NixOS would be very difficult to use.

It was easier to use NixOS than I expected; the main problems I ran into were when a tool would helpfully download some kind of binary, but since NixOS doesn't put its shared libraries where other Linuxes do, these programs wouldn't work. -- Though, for a popular-enough tool, most likely someone else already has a Nix package written that helps out.

There are other "escape hatches". e.g. I think something like distrobox could be used if native-on-NixOS stuff has problems. https://github.com/89luca89/distrobox

Nix can otherwise be difficult if you need to write some Nix code. There are several concepts in Nix which are foreign enough to how things have been done before; e.g. when building a package, it won't have access to $HOME; but, recent language tooling will often want access to $HOME. -- If something goes wrong, you may often need a wider and deeper understanding compared to if something goes wrong on a more typical Linux distribution.

For as difficult as it is, the trade-offs Nix makes are essentially "I'm going to put in a lot of effort now, so that I don't have to put in effort some time later". (This favours Nix when "effort later" is multiplied many times).

Overall, as a choice for "I need this to work right now", I'd recommend against NixOS (especially for someone who doesn't know Nix).

In addition to the other suggestions, you might want to check-out distrobox: https://github.com/89luca89/distrobox

It provides support for starting host commands within a container, and also exporting commands from containers to the host.

https://github.com/89luca89/distrobox ; Is what this is really built on.

I'm guessing the rest is just chrome, and getting a base OS of some form down, so you can use distrobox.

Read what the page says, then look one layer deeper. You may want to use distrobox in on your existing machine to try things out.

Great answers in this thread. I opt for distrobox [1] over toolbox.

https://github.com/89luca89/distrobox

Personally I run Steam (and pretty much every other gaming related program) through an Arch container using distrobox[0] on my NixOS setup. It runs without any issues and integrates with my system very well.

[0] https://github.com/89luca89/distrobox

> What makes a GUI app worth containerizing and CLI tools not worth containerizing?

Agree 100%, and podman/docker already exist.

The way I do it is to use [Distrobox](https://github.com/89luca89/distrobox) to use whatever distro's userspace has the thing I need (I use either the newer devel version of ubuntu or alpine), so if I need a newer version of a CLI tool I can get that without conflating it with the OS layer. It's a similar workflow to how OSX and Windows WSL do it.

So I'm just using the normal debian packages for everything, except it's in a nice split out container just for my userspace with access to all my data. This is the workflow from Fedora Silverblue, openSUSE's MicroOS and EndlessOS, which kind of forces you into the cloud native mindset, but you can run any distro this way.

So essentially this seems like another implementation of what toolbox and distrobox is implementing.

https://github.com/containers/toolbox/

https://github.com/89luca89/distrobox

With the downside of not having the option to select a Linux distro and being locked to the nixpkgs repositories?

> I am not sure what is the story of having NixOS as a server, but would not suggest to have it as a main OS

This was what I thought when I was learning nix. Once I used NixOS, I realised it's not quite that difficult. -- The two big differences: 1. Roughly, you only really need to care about the NixOS config about as frequently as you'd change system files in /etc/ in other Linux distributions. 2. Some programs (e.g. minikube) will download a binary automatically, and this doesn't work well with NixOS.

I've seen tools like distrobox https://github.com/89luca89/distrobox recommended as backups on NixOS, as well as the usual Docker / VMs.

I secretly suspect some of the reason NixOS is popular is it's less trouble than nix on non-NixOS. Whereas, nix on macOS, I've sometimes mixed compilers/libraries, which leads to difficult to discern problems.

https://github.com/89luca89/distrobox may be of interest to you.

Although I'd argue "Docker without containers" is a UX achieve.

Apologies, I posted this at the wrong level.

I am a Manjaro user currently but have used other distros in the past, including Ubuntu. Given that, I would obviously recommend Manjaro. There are a million reasons but, for development, I find the rolling release model far superior. On Ubuntu, especially an LTS release, you are going to find over time that the software versions on your machine are too old. This will lead to installing from source or Flatpak or what have you and then your system is a mess. Worse, it also means that when you eventually move to a newer Ubuntu release, things are likely to break ( more likely at least ). Manjaro means more software updates more frequently and more hassle keeping software at older or stable versions but always up-to-date software and no big system upgrade ever again. For developers, I find the Manjaro model superior.

I also highly recommend looking into Distrobox.

https://github.com/89luca89/distrobox

Distrobox is Docker but instead of heavy sandboxing, when you are in the container you can see your real home directory, your real device tree, your real process list, and your real Wayland server ( desktop GUI ). This means you can Distrobox into an Ubuntu 20.04 LTS terminal for example and be able to run any software available Ubuntu ( including graphical ) with an experience very much like Ubuntu is installed directly on your machine. Best of both worlds. Distrobox uses Docker though so you are not going to want to run containers in Distrobox. So the real distro still matters.

I am a Manjaro user currently but have used other distros in the past, including Ubuntu. Given that, I would obviously recommend Manjaro.

There are a million reasons but, for development, I find the rolling release model far superior. On Ubuntu, especially an LTS release, you are going to find over time that the software versions on your machine are too old. This will lead to installing from source or Flatpak or what have you and then your system is a mess. Worse, it also means that when you eventually move to a newer Ubuntu release, things are likely to break ( more likely at least ). Manjaro means more software updates more frequently and more hassle keeping software at older or stable versions but always up-to-date software and no big system upgrade ever again. For developers, I find the Manjaro model superior.

I also highly recommend looking into Distrobox.

https://github.com/89luca89/distrobox

Distrobox is Docker but instead of heavy sandboxing, when you are in the container you can see your real home directory, your real device tree, your real process list, and your real Wayland server ( desktop GUI ). This means you can Distrobox into an Ubuntu 20.04 LTS terminal for example and be able to run any software available Ubuntu ( including graphical ) with an experience very much like Ubuntu is installed directly on your machine. Best of both worlds.

Distrobox uses Docker though so you are not going to want to run containers in Distrobox. So the real distro still matters.

distrobox to manage the container: https://github.com/89luca89/distrobox Then just install XFCE and tiger VNC server inside it. Using VNC makes it easy to connect into a little isolated session that has its own theming, etc. vs. trying to send geany to my native X11/wayland server (which wouldn't theme it like windows 95).

You could also just run it in a browser window with a VNC HTML bridge, this would be a good base for that: https://github.com/accetto/ubuntu-vnc-xfce-g3

The easiest way to get Chicago95 setup is to run its GUI installer python script. I don't try to script it in a dockerfile or container setup.

Distrobox is handy for this: https://github.com/89luca89/distrobox

It just lets you reuse any docker image on your desktop (both podman and docker), and has some nice features like the ability to create a launcher shortcut on the host and transparently mapping your home directory. I switched to it full time, all my CLI work is just done in a container, and it's pretty transparent.

Distrobox let's you do the same(using docker or podman) imo and is pretty good.

https://github.com/89luca89/distrobox