Live data from Hacker News

I run a full Linux desktop in Docker just because I can

howtogeek.com

11–20 of 124 posts

Re: I run a full Linux desktop in Docker just because I can

#12
post #8

On Windows, doesn't this technically mean OP is running Linux inside a Linux VM inside Windows? From what I understand Docker is Linux tech and to use it anywhere else a (small) Linux VM is required. If true, I would just dispense with the extra layer and just run a Linux VM. Not to discourage experimentation though!

Almost.

For one thing, Docker is not really "Linux inside Linux". It uses Linux kernel features to isolate the processes inside a container from those outside. But there is only one Linux kernel which is shared by both the container and its host (within the Linux VM, in this case).

For another, running Linux containers in a Linux VM on Windows is one (common) way that Docker can work. But it also supports running Windows containers on Windows, and in that case, the Windows kernel is shared just like in the Linux case. So Docker is not exactly "Linux tech".

Re: I run a full Linux desktop in Docker just because I can

#13
post #2

I develop my apps in the most possible native way I can: deb packages, apt repo, systemd, journald etc. however I would like to also be able to run it in docker/vm. Is there a good systemd-in-docker solution for this to basically not run anything differently and not have to maintain two sets of systems?

You might be better served by Incus/LXD which run "Linux containers" (ie: a full distro including systemd, SSH etc) as opposed to OCI containers.

Re: I run a full Linux desktop in Docker just because I can

#14
post #8

On Windows, doesn't this technically mean OP is running Linux inside a Linux VM inside Windows? From what I understand Docker is Linux tech and to use it anywhere else a (small) Linux VM is required. If true, I would just dispense with the extra layer and just run a Linux VM. Not to discourage experimentation though!

Isn’t this the case on macOS too?

I desperately wish I could run docker properly (CLI) on the Mac rather than use docker desktop, and while we are making a dream list, can I just run Ubuntu on the Mac mini?

Re: I run a full Linux desktop in Docker just because I can

#15
post #2

I develop my apps in the most possible native way I can: deb packages, apt repo, systemd, journald etc. however I would like to also be able to run it in docker/vm. Is there a good systemd-in-docker solution for this to basically not run anything differently and not have to maintain two sets of systems?

You could use Nix to build the package and provide a nixos module and a docker image from the same derivation. Now you only have to manage three systems instead of two. /s

Re: I run a full Linux desktop in Docker just because I can

#16
I run full-headed Puppeteer sessions in Docker, with VNC for debugging and observation. I keep the instances as light as I can, but I suspect I'm most of the way there toward a "full" desktop experience. Probably just need to add a more full-featured window manager (currently I use fluxbox)

Re: I run a full Linux desktop in Docker just because I can

#17
post #8

On Windows, doesn't this technically mean OP is running Linux inside a Linux VM inside Windows? From what I understand Docker is Linux tech and to use it anywhere else a (small) Linux VM is required. If true, I would just dispense with the extra layer and just run a Linux VM. Not to discourage experimentation though!

Almost. For one thing, Docker is not really "Linux inside Linux". It uses Linux kernel features to isolate the processes inside a container from those outside. But there is only one Linux kernel which is shared by both the container and its host (within the Linux VM, in this case). For another, running Linux containers in a Linux VM on Windows is one (common) way that Docker can work. But it also supports running Win…

Can he install Wine in the Docker container to run Windows games from it?

Re: I run a full Linux desktop in Docker just because I can

#20
Does anybody have a good writeup/tutorial on doing similar things with Wayland? From my limited knowledge that might be with RDP instead, but there hasn't been anything more distilled as far as I know?

I've also done xpra in docker before; that's always felt as hacky as it sounds though.

Post reply on HN