this post was submitted on 22 Oct 2023
299 points (97.5% liked)

Linux

48634 readers
1391 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Gradience, Flatseal, Loupe Image Viewer, and Resources running on Ubuntu 16.04

Firefox 118.0.2 running on Ubuntu 16.04

Door Knocker, Collision, and Cartridges running on Ubuntu 16.04

ASHPD Demo running on Ubuntu 16.04, showing a notification through XDG portals

According to Door Knocker, almost half of the portals are unavailable on Ubuntu 16.04, compared to only one unavailable on Fedora 39 with GNOME, which means Flatpaks running here may have more limited capabilities than usual.

top 40 comments
sorted by: hot top controversial new old
[–] idefix 79 points 1 year ago (3 children)

Having a rock-solid Debian stable as a desktop with up-to-date softwares when it matters. It sounded impossible a few years ago but that might be achievable now with Flatpak. That's awesome.

[–] [email protected] 5 points 1 year ago (1 children)

I basically do this with Debian + Docker right now and yes, it is awesome

[–] [email protected] 7 points 1 year ago (1 children)

Try podman and distrobox. Podman runs as the local user and distrobox simplifies it so you can run GUI apps and have full file access

[–] [email protected] 1 points 1 year ago (2 children)

I nees to try this. I'm currently running Debian stable + Flatpak, but not being able to access all local files from things like Firefox is really forcing me to jump through hoops.

[–] [email protected] 4 points 1 year ago

Have you tried flatseal?

[–] [email protected] 1 points 1 year ago (1 children)

Really? It should be a XDG portal. What environment are you running?

[–] [email protected] 1 points 1 year ago (1 children)

Sway with xdg-desktop-portal-wlr. I can open a single file, but not directories of static content. So CSS, images, links all fail to load. Opening a single image or PDFs work fine.

[–] [email protected] 1 points 1 year ago

That's very odd. Maybe you are missing a dependency or the features you are looking for simply are not in older software

[–] [email protected] 4 points 1 year ago

Exactly what I usual say, the best of the two worlds. There are still a few annoyance though, the theme integration part that is easy to fix and not being able to get Ungoogled working with a KeePassXC when both are Flatpaks

[–] [email protected] 0 points 1 year ago

I also like nix because it is lighter on resources.

[–] [email protected] 66 points 1 year ago (1 children)

Cool testament to flatpak's strengths. If an OS update makes a breaking change it won't affect the apps. Makes sense that it works backwards too but I never thought to do it.

[–] [email protected] 5 points 1 year ago

but only because the apps don't get the updates

[–] [email protected] 40 points 1 year ago* (last edited 1 year ago) (4 children)

Ok, so it’s time for me to do some research on Flatpaks now. I’m an old schooler from Redhat days and haven’t kept up with the new stuff all that much.

[–] [email protected] 31 points 1 year ago* (last edited 1 year ago) (2 children)

Flatpaks is a distro independent way of installing apps, similair to snaps. However it does not require a proprietary backend like snaps do.

It uses “runtimes” that contain the libraries that are required for the app, such as freedesktop, gnome, kde and elementary. Each app requests a specific runtime and version which prevents library conflicts.

Although runtimes are shared the different versions can take up quite a bit of space. This is a common criticism of Flatpak and one of the major drawbacks compared to the distro’s native package manager. Another disadvantage is that the sandboxing can cause issues with the functionality of the app if it requires certain system functionality. Authors (and users) can configure which parts of the system to expose (dbus, files, network, etc) but sometimes this is done incorrectly (looking at you Discord) which can cause the aforementioned issues.

One of the major advantages is that it simplifies the work for Application developers, they can target 1 system and don’t have to package the application and it’s libraries for each distro. It also means that the applications aren’t dependent on the distro’s for newer versions. You can use Debian stable with a version of an app that came out yesterday.

I personally tend to use Flatpaks quite often except for software that is included in the distro by default and apps that have issues with sandboxing such as Steam and VSCode.

[–] [email protected] 10 points 1 year ago (1 children)

Sounds a bit like docker and its containers?

[–] [email protected] 17 points 1 year ago (2 children)

Yes and no. It's much better suited for desktop applications. Try to run something playing audio in Docker. It's doable but not pleasant in any way.

[–] [email protected] 7 points 1 year ago

Well yeah, I only meant it sounds like a similar idea, I’d be surprised if it was powered by docker.

[–] [email protected] 3 points 1 year ago* (last edited 1 year ago) (1 children)

It’s certainly doable to run desktop apps in containers, have you tried Distrobox?

[–] [email protected] 3 points 1 year ago

No, I didn't. Looks interesting. Not something I'm looking for right now but I'll keep it in mind.

[–] [email protected] 9 points 1 year ago (1 children)

Although runtimes are shared the different versions can take up quite a bit of space. This is a common criticism of Flatpak and one of the major drawbacks compared to the distro’s native package manager.

It's actually not that much of a concern, since Flatpak does deduplication behind the scenes - yes, even between different versions of runtimes.

https://blogs.gnome.org/wjjt/2021/11/24/on-flatpak-disk-usage-and-deduplication/

[–] [email protected] 2 points 1 year ago

I’m aware about the deduplication but last time I checked it was still using roughly 30GiB of storage.

[–] [email protected] 18 points 1 year ago* (last edited 1 year ago)

As well as running on all distros, it also provides other benefits:

However, some applications don't work as well because of the sandbox, but I think this will change with the rising popularity of Flatpak, as more developers will use portals instead of direct access. Also, there are some bugs and missing features, like how heavy use of the org.freedesktop.Flatpak portal for dbus causes a memory leak (https://github.com/flatpak/xdg-dbus-proxy/issues/51), but it's overall pretty good. Most applications I use are Flatpaks.

[–] [email protected] 7 points 1 year ago (1 children)

Flatpaks are to distros what Alpine is for docker containers. A base for creating distro agnostic desktop applications. It's really cool and has picked up quite some good support within the Linux community.

[–] [email protected] 12 points 1 year ago

I think that Flatpak being Docker for desktop applications would be a better comparison.

[–] [email protected] 5 points 1 year ago (1 children)

Mint integrates flatpak seemlessly into its graphic package management and update tools.

[–] [email protected] 5 points 1 year ago* (last edited 1 year ago)

KDE's "Discover Store" (gui package manager) also does as well, which is awesome. While I don't like the idea of packaging system libraries with software due to the fact that they can and will sit out of date and hold on to vulnerabilities, I do like what flatpak is trying to achieve and the fact that we have a very solid leader in the area, putting the closed-source proprietary Snaps system firmly in second place.

[–] [email protected] 13 points 1 year ago (1 children)

Another big advantage of Flatpaks is the portability, since they live in your home.

I've had to reinstall distros and swap to different ones a decent amount. I simply backup and restore my home dir, and all my flatpaks get carried over, appear in my app launchers, and usually have their app data saved so I don't even have to relogin/reconfigure to stuff. It's as if I had just closed and opened it again.

It's crazy this works even when completely swapping distros.

[–] [email protected] 8 points 1 year ago* (last edited 1 year ago) (2 children)

I run Arch Linux (by the way) on my work laptop. One time Unity botched their game engine on Arch, so I had to rollback my whole system to keep an older version of GTK just so I could keep doing my work.

For a good 6 months, any up-to-date application had to be a Flatpak, because updating my system was off the table. Completely saved my bacon, and let me stay on top of rolling-release apps with ease.

[–] [email protected] 3 points 1 year ago

You could set up a development environment using distrobox in an arch container and keep the downgraded packages installed in there if it happens again

[–] [email protected] 1 points 1 year ago
[–] [email protected] 4 points 1 year ago (1 children)

Lol like yeah that is its point and also its weakness

[–] [email protected] 16 points 1 year ago (1 children)
[–] [email protected] 0 points 1 year ago (2 children)

you are still running 7 year old code with no security updates

[–] [email protected] 9 points 1 year ago (2 children)

@nicman24 Ubuntu 16.04 ESM will have security updates till 2026

[–] [email protected] 1 points 1 year ago

oh nvm i read something in the title wrong. also dont count on fast fixes for the kernel they have repeately lagged or even never arrived in older lts

[–] [email protected] -1 points 1 year ago* (last edited 1 year ago)

Not the universe. Ubuntu is one of the most unpatched systems out there.

[–] [email protected] 7 points 1 year ago (1 children)

This is a completely patched Ubuntu 16.04 through the Extended Security Maintenance program.

I would have tried this on Ubuntu 14.04 (supported until 2024) but Flatpak never supported 14.04 in the first place.

[–] [email protected] 6 points 1 year ago (1 children)

They are talking about the code sitting inside the flatpak I think. If a developer fails to continue updating the system libraries a flatpak contains, you retain old vulnerabilities you could have otherwise fixed with a sudo apt update && apt upgrade or a sudo pacman -Syu

[–] [email protected] 3 points 1 year ago

The runtimes are well maintained and it shows warnings on no longer maintained versions. It’s less of a problem in practice.

[–] [email protected] 3 points 1 year ago

what's the one missing on Fedora 39?