Posted on

TLDR;

What is a Desert Island App? They are the apps that I truly rely on, that I would take on my laptop to a desert island (with internet), and are just core to my digital life and work. Flatpak and Flathub is for sure one of my Desert Island Apps.


Introduction

Linux desktop app distribution has had different approaches over the years - from Debian (deb), Fedora (rpm), Arch (PKGBUILD), and others, but all dealing with varying library versions across different distributions. Users were often stuck between outdated "stable" repositories or risking system breakage by adding third-party repos (the dreaded "dependency hell").

Then came Flatpak (originally known as xdg-app when Alexander Larsson first started working on it).

Today, Flatpak is not just another package format—it is for me the gold standard for desktop software distribution on Linux. It represents a beautifully engineered compromise that respects both security and user experience, running seamlessly on everything from SteamOS to Debian and Fedora Silverblue.


Achieving Balance

What makes Flatpak truly special is how it solves the tension between isolation (for security) and integration (for usability).

In other environments, sandboxing is often an all-or-nothing affair. If you sandbox an application too tightly, it can't open a file chooser, print a document, or share your screen. If you integrate it too deeply, you lose security.

Flatpak solves this with a two-pronged architecture:

  1. The Sandbox (Bubblewrap): Flatpak uses bubblewrap under the hood to create isolated unprivileged user namespaces. Applications run with their own view of the filesystem, network, and process space.
  2. The Portal (XDG Desktop Portals): This is the secret. Instead of giving an application direct access to your microphone, camera, or home directory, the application talks to a Portal API. When the app wants to open a file, the system pops up a native file chooser outside the sandbox. Once you select the file, the portal passes only that specific file descriptor back to the app.

This means you get modern, granular macOS/Android-style permissions on Linux without breaking the desktop experience. It just works.


Comparing the Competitors

How does Flatpak hold up against other software management systems? Let's look at the pros and cons of each.

1. Flatpak

  • Pros:
    • True Sandbox Security: Granular control over permissions with portal integration.
    • OSTree Deduplication: Uses OSTree (like "Git for OS binaries") to share common runtimes (GNOME, KDE, Freedesktop), saving massive amounts of disk space.
    • Decentralized but United: Anyone can host a Flatpak repository, but Flathub serves as a fantastic, semi-official hub.
    • Consistent Across Distros: A Flatpak built today runs identically on Ubuntu, Fedora, Arch, or openSUSE.
  • Cons:
    • Not for CLI/System Services: Flatpak is intentionally designed only for desktop (GUI) applications.
    • Disk Footprint: If you only have one Flatpak app, downloading the entire runtime might feel heavy (though this cost amortizes quickly as you add more apps).

2. Snap (Canonical / Ubuntu)

  • Pros:
    • Versatile: Can package CLI tools, system daemons (like databases), and desktop apps alike.
    • Canonical Backing: Deeply integrated into Ubuntu with a massive enterprise ecosystem.
  • Cons:
    • Proprietary/Centralized Backend: The Snap Store backend is closed-source and owned exclusively by Canonical. You cannot host your own independent Snap repository easily.
    • Performance: Snaps use compressed SquashFS loops, leading to notoriously slow cold-startup times (especially for complex apps like browsers).
    • Intrusive Updates: Auto-updates can sometimes be forced on the user with limited control.

3. AppImage

  • Pros:
    • Zero Install: Just download a single file, make it executable, and run it. No daemons, no root, no setup.
    • Ultra-Portable: Perfect for offline use or quick trials of an application.
  • Cons:
    • No Sandbox by Default: AppImages run with full user privileges. If an AppImage is compromised, your whole home directory is vulnerable.
    • No Centralized Updates: Updating an AppImage usually requires downloading a whole new file manually, unless the developer implements a custom updater.
    • Poor Desktop Integration: Does not automatically integrate with your system's application launcher or file associations without third-party helpers.

4. Native Package Managers (APT, DNF, Pacman)

  • Pros:
    • Peak Efficiency: Native compilation, shared dynamic libraries, and zero overhead.
    • System Integrity: Keeps the entire operating system consistent and minimal.
  • Cons:
    • Dependency Hell: Upgrading one application can force upgrades on system libraries, potentially breaking other software.
    • Slow Update Cycles: Stable distributions (like Debian or Ubuntu LTS) often have outdated versions of user-facing desktop applications.

A Massive Kudos to the Pioneers

Flatpak did not happen by accident. It is the result of years of dedicated work by some of the most brilliant minds in the free software ecosystem.

We owe a massive thank you to:

  • Alexander Larsson (Red Hat): The original architect who pioneered xdg-app and laid down the core concepts of OSTree runtimes and Bubblewrap integration. His vision of a decoupled desktop application layer has transformed how we use Linux.
  • The Red Hat & Fedora Teams: For providing the engineering muscle, sponsoring developers, and proving that immutable base systems (like Silverblue) combined with Flatpaks are the future of stable computing.
  • The Endless OS Team: An early adopter that pushed Flatpak to its limits, ensuring that the packaging format worked flawlessly in offline, low-bandwidth, and education-focused deployments around the world.
  • Collabora: For their continuous contributions to bubblewrap, pressure testing the sandbox, and ensuring Flatpak's enterprise-grade reliability.
  • The GNOME and KDE Communities: For embracing Flatpak fully, updating their toolkits to natively support XDG Desktop Portals, and making sandboxed apps look and feel native on any desktop environment.
  • The Flathub Maintainers & Contributors: For creating an open, community-driven application hub that has become the de facto app store for Linux, making app publishing incredibly straightforward for developers.

A huge THANK YOU to everyone who has worked on Flatpak, it is a marvel and an amazing platform that helps me, and millions of other Linux users, every day.

For those reasons, Flatpak is definitely one of my Desert Island Apps. What are yours?

Table of Contents