News for hackers. Stuff that matters.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by jjice on Thursday July 06, 2023 @05:34PM (#36623404)
So why does Ubuntu push Snaps so hard? They've been doing this for year and I still have no idea, since pretty much everyone I know would rather a deb file (myself included). What's their gain?
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by jcastro on Thursday July 06, 2023 @05:36PM (#36623433)
The linux desktop is in the middle of moving to a zero trust model: https://www.ypsidanger.com/the-distribution-model-is-changin...
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by JohnFen on Thursday July 06, 2023 @05:41PM (#36623484)
Damn, that was a depressing read. If that's how things are going, then it really is past time for me to stop using Linux entirely. This is feeling like the final straw in a series of things that have been pushing me away.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by jcastro on Thursday July 06, 2023 @05:48PM (#36623563)
What are your concerns?
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by JohnFen on Thursday July 06, 2023 @06:06PM (#36623818)
Oh, I have quite a few of them, from increased resource usage, proprietary aspects, through forced updating and more. The forced updating is particularly unacceptable.

But, the 10,000 ft view is that they reduce the amount of control I have over my system. They offer restrictions I chafe at while giving me no benefit that I care about.

I'm not going to sit here and say they shouldn't exist. That they're not to my taste doesn't mean that others who like them shouldn't have them. But they're not to my taste at all.

After seeing systemd getting widely adopted (also not to my taste), if snaps (or flatpacks, although I am less allergic to those) join the party then that's just a clear indication that the Linux world and I have diverged too much and I need to move on.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by WhyNotHugo on Thursday July 06, 2023 @06:13PM (#36623920)
Alpine feels a lot like a BSD to me, and I’m very happy with it.

But this bloatification is happening all over the place. Firefox is starting to have more and more dependency on flatpak’s daemons, even if you don’t use flatpak. These daemons are becoming the de facto standard for some interfaces too sadly. This also means that a lot of software is a lot less portable.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by JohnFen on Thursday July 06, 2023 @07:22PM (#36624706)
I'm just going to move to BSD entirely, I think.

I'm saddened to hear that FF has dependencies on flatpack daemons, but I'm not surprised by it. The direction Linux is going seems very clear to me, and I expect more of that sort of thing as time goes on.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by Aerbil313 on Thursday July 06, 2023 @08:46PM (#36625490)
Meh. There’s just too much technical debt all over the place. Not even BSDs suffice from the POV of what an OS can be. A new modern OS written today with lessons taken from the past would solve the inherent pains of all existing ones. My dream is to do that. Just a dream rn tho.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by amelius on Thursday July 06, 2023 @06:15PM (#36623941)
It's a quite powerful idea to run every package in its own container (sandbox).

However, it depends on the implementation and Snap just sucks.

(Note that the default Unix assumption is that no users can be trusted but all applications can be trusted, which is wrong imho. Containers provide a way out of this, but things get messy very fast.).

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by goodpoint on Thursday July 06, 2023 @06:41PM (#36624257)
The sandbox is not going to protect users from spyware telemetries, bad security for the application itself, ads, and so on.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by amelius on Friday July 07, 2023 @04:32AM (#36628908)
Yes, but right now my smartphone is more secure wrt apps than my desktop, which is odd.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by goodpoint on Friday July 07, 2023 @06:30AM (#36629689)
No, you can use a security oriented distribution, plus sandbox the applications you use.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by fsflover on Friday July 07, 2023 @05:37AM (#36629321)
> The sandbox is not going to protect users from ... bad security for the application itself

Your other data, in other sandboxes, is protected though.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by goodpoint on Friday July 07, 2023 @06:29AM (#36629683)
Sure, but that's far from enough.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by fsflover on Friday July 07, 2023 @06:35AM (#36629722)
This is almost the only working security approach: security by compartmentalization.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by goodpoint on Tuesday July 11, 2023 @07:08AM (#36679297)
Not at all, it's not enough.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by JohnFen on Thursday July 06, 2023 @07:17PM (#36624650)
> It's a quite powerful idea to run every package in its own container (sandbox).

It is, but I also actively don't want every package to run in its own container. I'd rather containerize select applications that I choose.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by amelius on Friday July 07, 2023 @04:34AM (#36628921)
Yes, this is one of many reasons why Snap sucks.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by fsflover on Thursday July 06, 2023 @06:11PM (#36623881)
> the Linux world and I have diverged too much and I need to move on

I moved to Qubes OS and like it.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by rlpb on Thursday July 06, 2023 @06:44PM (#36624300)
> The forced updating is particularly unacceptable.

Snaps allow you to hold updates indefinitely now: no forced updates any more. Use "snap refresh --hold <some snap name>". See https://snapcraft.io/docs/keeping-snaps-up-to-date#heading--....

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by JohnFen on Thursday July 06, 2023 @07:07PM (#36624547)
Oh, that's good news!
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by apple4ever on Friday July 07, 2023 @12:49AM (#36627293)
Oh wow I missed they finally gave in and fixed that. When did that happen?
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by makeitdouble on Thursday July 06, 2023 @07:29PM (#36624777)
I haven't run a desktop linux for years so this might be completely off, but what I got from it was there will two majors paths:

- you're a hardcore oriented distro, you assume most things will be built from source, follow all of your dependencies and maintain the glue for your distro. Gentoo/Slackware style。

- you value convenience and go the snaps/flatpack route.

And you can still go the convenience path while building some specific apps from source, but there will be a bigger gap to bridge and it won't make sense formost applications.

I get the shift, as we're already seeing it, even outside the cloud, I think it's still the best of both worlds. I compare that to how I'm running a natively compiled postgres version but a containerized mysql because it was too much of a pain to match all the dependencies.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by JohnFen on Friday July 07, 2023 @10:51AM (#36632617)
But there really needs to be a third path, in between the two you cite. Most Linux distros have been that third path.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by abeyer on Thursday July 06, 2023 @06:05PM (#36623795)
Personally mine are the fact that this isn't really "zero trust", but more "infinitely diffuse trust" where every user has to trust every application. None of the packaging alternatives I'm aware of seem to yet have their security story in line where they are either secure enough (without breaking most software) to not have to trust every application or provide some level of assurance themselves comparable to the debian maintainers.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by srcthr on Thursday July 06, 2023 @06:06PM (#36623819)
This model destroys any reason for software to be open source. What's the point of having source code if you just run the binary provided by some party?

Reminds me of the early days of the tensorflow where everyone used whatever binary package worked an no one could run anyone else's code because people kept getting stale binaries somewhere in the stack.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by jcastro on Thursday July 06, 2023 @06:21PM (#36624019)
The packaging format doesn't change source code availability or restrictions.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by goodpoint on Thursday July 06, 2023 @06:42PM (#36624268)
On a practical level it's completely different.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by eichin on Thursday July 06, 2023 @07:12PM (#36624606)
What's the snap equivalent of "apt-get source"? Failing to find that meant for me, it was time to start purging snapd from new installs entirely (and to start fretting about ubuntu starting to be philosophically incompatible with what I want out of a system.) Fortunately even with 23.04 (server) that still seems to leave an entirely working system.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by michaelt on Thursday July 06, 2023 @06:44PM (#36624299)
Snap makes it easier to distribute closed-source software like skype - but people running linux on the desktop generally have no great love of closed source software.

For open source software, snap is the same software, but slower, more broken and with worse upgrades.

Snap's changed the firefox update process so I now have to run 'sudo snap refresh' and wait for a download, where before I just closed and reopened it. Maybe it'll make my running application's dock icon disappear, hope you always use alt+tab instead of the dock. Snap can install ffmpeg - but I can't feed a screen recording to vaapi for compression because whoever set up the sandboxing forgot to allow that. Good luck sharing anything from, say, ~/.config/ on, say, discord - you get a silent unexplained failure, because hidden folder access is blocked by the sandbox. Installing a browser? With snap you get three copies; you can adjust refresh.retain down to only keep 2 copies - but 1 copy is out of the question.

There's a reason canonical has to force snap down people's throats, and it's because nobody uses it by choice.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by BaseballPhysics on Thursday July 06, 2023 @06:31PM (#36624123)
You say that like the "Linux desktop" is a monolith. What leads you to believe this is a widespread movement outside of RHEL and Canonical?
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by jcastro on Thursday July 06, 2023 @06:38PM (#36624222)
They're just catching up to Android, ChromeOS, and SteamOS. The market rejected traditional needs-a-sysadmin linuxes on client a long time ago.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by BaseballPhysics on Thursday July 06, 2023 @06:55PM (#36624412)
That's not an answer to my question. For example, I see no evidence Debian is moving toward app images as the standard way to distribute software. Same goes with Arch and I'm sure many others.

And btw SteamOS is absolutely not a sandboxed environment. It just has a read-only OS filesystem so they can safely blow it away upon upgrade.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by jbicha on Friday July 07, 2023 @08:24AM (#36630638)
Debian and Arch are exceptions. I believe maintainers of every other mainstream distro are exploring immutable distros or at least shipping confined apps.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by goodpoint on Thursday July 06, 2023 @06:37PM (#36624202)
zero trust meaning that you cannot trust your desktop anymore
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by JohnFen on Thursday July 06, 2023 @05:36PM (#36623440)
My hypothesis is that if everyone used snaps, it would reduce the complexity of packaging by reducing or eliminating dependencies that need to be installed separately.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by WhyNotHugo on Thursday July 06, 2023 @06:10PM (#36623872)
It’s a proprietary package management system (only the client part is open source, so it’s kinda MSFT-style open source).

The obvious answer is: vendor lock in. Once Ubuntu is snap-only you won’t be able to host your own package repositories, since it’s their secret code.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by rlpb on Thursday July 06, 2023 @06:53PM (#36624392)
The package hosting protocol is relatively trivial. I believe a couple of alternative implementations have been written, but I'm not sure they're maintained because there's no point. Anyone can publish to the Snap Store. Because snaps are sandboxed at the client end, there's no gate except automated checks.
Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by jeroenhd on Thursday July 06, 2023 @06:16PM (#36623950)
Canonical sells access to the snap store. It's part of their Ubuntu IoT strategy.

Uploading public applications is free. Uploading proprietary software is a business model.

It also pretty much locks Ubuntu users in, because no other project uses snaps, so if an app chooses snap for their distribution method (certbot, for example) it suddenly becomes a lot easier to just download Ubuntu than it is to install Snap for a foreign platform.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by rlpb on Thursday July 06, 2023 @06:49PM (#36624346)
> it suddenly becomes a lot easier to just download Ubuntu than it is to install Snap for a foreign platform

That's an exaggeration. It's about as easy to install snap support for a non-Ubuntu as it is to install any other third party app on that platform. And the latter case is exactly what you're trying to achieve by trying to install a third party app on that platform in the first place, so by definition it can't be significantly harder than any alternative method.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by simion314 on Thursday July 06, 2023 @06:24PM (#36624052)
> since pretty much everyone I know would rather a deb file (myself included).

Not me, for programs that are not from the repos I do not like debs.

I needed to install dubious apps like Skype,Slack, Some Pdf Editor etc. With deb I would give them root , so I either find an app image or snap, or try to unpack the deb file and attempt to run the binaries without root.

I also installed one a server some CLI snaps, they did their job and I did not had to build them from source.

I agree from things that are in the repo I prefer the debs 99% of the time.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by rlpb on Thursday July 06, 2023 @06:42PM (#36624276)
Debs work really well when they are shipped as part of the distribution deb archive itself. They work really badly when third parties try to use them to provide add-on software to an existing distribution release.

The main problem that Snaps solve is this latter case: when third parties are trying to ship directly into someone's distribution installation[1].

Often third party debs appear to work OK, but then break future distribution upgrades. By then users have forgotten about the third party software that has hacked itself into their system, and blame the distribution for their upgrade failure. The problem is that distribution debs are designed to provide metadata about what has changed so that the package manager can accommodate. But it's not possible for distribution debs to be aware of the third party debs to handle those changes. So things break.

The breakages caused by debs aren't just limited to future distribution upgrades. A bad third party deb package can break your entire system. We routinely get reports where it turns out that this is what happened to our users!

There's also the problem of dependencies. If a third party app needs a bunch of dependencies, then they can't realistically bump those dependencies on the system as a whole without regressing all the other apps that need older versions of that dependency. So they have to bundle their dependencies, and this is something else that regular deb tooling doesn't handle well. You can theoretically construct a deb that bundles all its dependencies, but then that's exactly what snaps and snap tooling handles better - that's half the point. Nix only partially solves the problem by better supporting concurrent installation of multiple versions of those dependencies. But those concurrent versions would still each have to be maintained; that's something that distributions try to avoid by picking one version of each dependency and making the entire distribution release work with just that one. Moving that maintenance responsibility to each third party app developer, and having the packages bundle their dependencies, is the other solution. This was already happening with deb packages like for Firefox. Firefox upstream bundles nearly everything, and the debs (eg. in Debian) do the same for most of their dependencies. Snaps just call a spade a spade and are designed around it.

You also wouldn't really expect a third party app to have access to everything on your system. Say for example you download and install some game app to try out. Do you really want it to have access to your online banking browser session? The game developer might not secure their development infrastructure as if someone's trying to steal their users' money, because that's expensive and they're only shipping a game. But if you install their game, then that's what you risk. That game developer's infrastructure is suddenly an attack vector for an adversary that wants to get to your online banking session. On iOS and Android, each app only has system-mediated access to everything outside its sandbox. Debs fundamentally cannot provide this separation, so if you install third party debs then you're giving all those third parties access to everything, which really is unacceptable in modern security practice. Snaps give you that sandboxing.

So that's what snaps are for: 1) bundling dependencies, because that's necessary in world of third party software that ships independently of the distribution; and 2) sandboxing, because that's necessary in a world of third party software if you don't want to give all those third parties and their adversaries root on your system.

If you don't want third party apps, and only want what your distribution ships in a curated manner, then you don't really need snaps. But consider that Firefox is essentially a third party, non-curated app, regardless of your distribution or how it was packaged! See [1] below.

Snaps are also immutable, which really helps with stability and upgrade and revert cases. This is more relevant for snap-only systems like in IoT, not the Ubuntu desktop. In an IoT deployment you can't tell the user to run "apt-get -f install" to fix up the system because power got interrupted during an upgrade - because that's how debs work.

In years gone by, Ubuntu tried really hard to make third party debs work. But it didn't work for various reasons. In the meantime, it became the norm for third parties to ship debs together with all of their problems, since there was nothing better possible at the time. This is what snaps solve.

Disclosure: I work for Canonical. But here I am speaking for myself, not my employer. I'm not involved in the design of snaps, but as a distribution developer, it's clear to me what problems they solve.

[1] Packages like Firefox also use snaps because even as a deb it's really not the case that Firefox is curated by the distribution and mostly unchanged after release any more. So it suffers from mostly all the same problems that third party debs do.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by Aerbil313 on Thursday July 06, 2023 @08:57PM (#36625579)
> Nix only partially solves the problem by better supporting concurrent installation of multiple versions of those dependencies. But those concurrent versions would still each have to be maintained

How so? Every dependency of every dependency is in the nix store and they’re all immutable. A nix package installed will work forever because its environment can’t change. Am I not right?

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by rlpb on Friday July 07, 2023 @04:05AM (#36628676)
All deb package versions are immutable too!

Bugs and security issues are found from time to time. When that happens, every occurrence in use needs an update. If ten different incompatible versions of a package are in use, they all need to be replaced. That's more work than one per traditional distribution release.

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by dmr_92 on Friday July 07, 2023 @05:46AM (#36629390)
Does your comment still ring true if you replace "snap" with "flatpak"?

(What I'm getting at is: why does it make sense for Canonical to define its own sandboxed application format when another one already exists?)

Re:Ubuntu 23.10’s New Software App Will Demote Debs (Apparen... by rlpb on Friday July 07, 2023 @06:33AM (#36629712)
In my reply I focused on why we need a bundled, sandboxed packaging format in the first place, since many people are sceptical just about that. So you're right in that I didn't go into any of the differences.

Snaps solve a bunch of problems that are out of scope of Flatpaks, such as CLI apps and the packaging of kernels and other hardware-level pieces. This allows for an entirely snap-based system that is immutable and atomically updated, which is essential for IoT devices to be reliable.

If you look at the history of snaps, they are an evolution of click packaging, which were created for the Ubuntu phone that is no more. But the history goes back further than that - back to Ubuntu's App Review Board and (deb based) third party app packaging system, which failed for exactly the reason that deb is an unsuitable packaging format for third party apps.

If you look at the history of Flatpaks, you'll find that their initial release was at a similar time to snaps. But given that they don't solve a bunch of problems that snaps do, what was/is Canonical supposed to do? Ditch snaps entirely and drop their IoT support? Integrate IoT support into Flatpaks? Do Flatpak upstream even want that? Look at the history of Canonical wanting to ehnance GNOME, and the history of how Unity began, to see how that doesn't seem like it would be a practical way of delivering functionality to users in a reasonable period of time.

Consider that it is Ubuntu that is at the centre of this third party app packaging problem. It's Ubuntu that everybody targets first with their third party debs. For the same underlying reason, it's Ubuntu that gets more user support requests because of bad third party debs than every other distribution. It makes sense that Ubuntu developers are best to understand the problem and develop a solution.

So yes, we've ended up with two parallel contenders. But I don't think it's reasonable for Canonical to have done anything differently in regard to Flatpak. It appeared at the same time while Canonical had already been working away at the problem for years, doesn't solve or even try to solve all the problems that snaps are designed to solve, and those problems appear to be out of the scope of Flatpak anyway. As much as critics frame them as like-for-like options that Canonical could just decide to switch over, they simply aren't and thus "simply switching" doesn't even make sense.

As for "another one already exists", that statement could just as well apply the other way round: look at the timelines!