News for hackers. Stuff that matters.
Re:Snaps are universal Linux packages by matthewbauer on Thursday February 02, 2017 @11:25PM (#13557671)
So there are a couple of different projects trying to be distro-agnostic/sandboxed/multi-version package managers:

- Snappy

- FlatPak

- AppImage

- Nix

Snappy is an Ubuntu/Canonical project and FlatPak is a Fedora/RedHat/FreeDesktop project. Snappy and FlatPak are remarkably similar and kind of mirror the DEB/RPM spit. Nix and AppImage are independent.

AppImages resemble macOS's app bundles in that they can be run directly without installation. Snappy, FlatPak, and Nix need to install to a root directory, /snap, /var/lib/flatpak/, and /nix respectively. FlatPak and Snappy need a runtime daemon but Nix and AppImage don't.

AppImage, Snappy, and FlatPak include all of the dependencies in one package. Nix packages just include hash names and install as needed.

Re:Snaps are universal Linux packages by qznc on Friday February 03, 2017 @03:26AM (#13558538)
FlatPak is intended for Desktop only. "is not a good match for a server" http://flatpak.org/faq.html

In contrast, Snappy aims for much more "Package any app for every Linux desktop, server, cloud or device" https://snapcraft.io/

I cannot find how many packages they have currently. I hope that FlatPak has more than the 11 applications listed on the website. http://flatpak.org/apps.html

FlatPak does not provide a central repository, while Snap has https://uappexplorer.com/. After install flatpak, it takes three (!) commands (on cli) to install LibreOffice. http://flatpak.org/apps.html

Snap has stuff like pulseaudio (audio daemon) or ogre (rendering engine) in the repo. That seems weird, because these are not applications. The first belongs into the base system, the second into a development environment.

Re:Snaps are universal Linux packages by ugos on Friday February 03, 2017 @09:27AM (#13559965)
"FlatPak does not provide a central repository"

This is something I particularly like about FlatPack. I hope we can go towards a decentralized package distribution system where the app store just has a list of official flatpack repos. You update the latest Firefox from the repo at mozilla.org, the latest Blender from blender.org, etc... of course this needs mozilla, blender.org, etc... to package the app (but they already do it for win, mac and .deb anyway). So you always have the latest version and it is provided by the official website and not a central Canonical repo

Re:Snaps are universal Linux packages by qznc on Friday February 03, 2017 @11:09AM (#13560764)
The problem is installing always takes at least two steps: Add repo, install package. Maybe even a third: Verify/add key.
Re:Snaps are universal Linux packages by mhall119 on Friday February 03, 2017 @01:47PM (#13562120)
Snaps are usually published by the official upstream, not by Canonical. The Snap store allows them to upload their binary packages directly and immediately. That means you get the latest official releases without having to find out where to get the latest official releases.
Re:Snaps are universal Linux packages by StavrosK on Friday February 03, 2017 @10:04AM (#13560199)
Isn't that the same as apt and PPAs?
Re:Snaps are universal Linux packages by ugos on Friday February 03, 2017 @10:16AM (#13560292)
yep indeed, so to me (but I don't know if I'm interpreting all this correctly) Flatpack seems to push towards a PPA like system for distribution but with a SandBoxed App over one or multiple Runtime for execution
Re:Snaps are universal Linux packages by sergiusens on Friday February 03, 2017 @04:09AM (#13558687)
pulseaudio and similar exist for things like Ubuntu Core which only works with snaps.
Re:Snaps are universal Linux packages by curt15 on Friday February 03, 2017 @08:57AM (#13559772)
One would hope that Ubuntu eventually exercises some quality control over the snaps in their store. Otherwise what's the point of a centralized store? Currently uappexplorer shows a whole bunch of "hello world" apps.
Re:Snaps are universal Linux packages by mhall119 on Friday February 03, 2017 @01:49PM (#13562141)
We don't plan to restrict publishing of apps, but we can be judicious in which ones we promote on the front-end
Re:Snaps are universal Linux packages by sjellis on Friday February 03, 2017 @02:27AM (#13558355)
> Snappy is an Ubuntu/Canonical project and FlatPak is a Fedora/RedHat/FreeDesktop project. Snappy and FlatPak are remarkably similar and kind of mirror the DEB/RPM spit.

This isn't actually a good analogy, because Flatpak was designed from the ground-up to be vendor-neutral. For example, the "runtimes" that provide the virtual Linux distribution for applications to work in are built with packages and tools from the Linux Foundation's Yocto project. Similarly, the code is deliberately hosted on GitHub with no CLA so that all contributors are on neutral ground (there is at least one Debian developer involved). The main developer is a Red Hat employee, and could have used Fedora or CentOS packages, tools and infrastructure, but explicitly chose not to do that, to protect Flatpak's neutrality. He also builds Flatpak for Ubuntu, Arch and other distributions, so that people can freely use Flatpak on their systems even where it isn't currently supported by their distribution of choice.

Re:Snaps are universal Linux packages by Sean1708 on Friday February 03, 2017 @08:12AM (#13559534)

  > because Flatpak was designed from the ground-up to be vendor-neutral
As have all the others, hence the "distro-agnostic" part of Matthew's comment.
Re:Snaps are universal Linux packages by ugos on Friday February 03, 2017 @10:08AM (#13560236)
True Snap are technically distro-agnostic but still Snap is surrounded by a "brought to you by Canonical™" feeling.

Even if you look at the terms used : https://snapcraft.io/docs/core/store :

"The main way of distributing snaps to snapd systems is through the Ubuntu Store"

So indeed there is the "other store" section which mention you can host your own store but it's clearly not emphasized.

Even the term of Snap "store" vs Flatpack "repo" seems to indicates a more decentralized/agnostic direction of Flatpack.

On flatpak.org/apps.html you can see LibreOffice hosted by documentfoundation.org and MonoDevelop hosted by mono-project.com. They're not all hosted by their respective foundation/website, but still it kinda seems like it is the direction flatpack is pushing for.

So "technically" they all are distro-agnostic, but in terms of distribution system one is pushing for a centralized Canonical-hosted store while the other seems to be going towards a "each foundation will host their app"

Re:Snaps are universal Linux packages by dustinkirkland on Friday February 03, 2017 @02:09PM (#13562322)
Omg! How dare an open source project, led by Canonical, have a "brought to you by Canonical" feeling! That's just awful. Did you know that Canonical also doesn't contribute upstream, and instead uses that time to club baby seals for fun! I seen em!
Re:Snaps are universal Linux packages by wmf on Friday February 03, 2017 @02:18PM (#13562407)
IMO Flatpak has a pretty "brought to you by GNOME/Fedora" feeling.
Re:Snaps are universal Linux packages by sjellis on Friday February 03, 2017 @07:46PM (#13564796)
GNOME and Fedora are definitely further ahead, since the lead developer for Flatpak is a long-time GNOME contributor as well as a Red Hat employee. There are Flatpak contributors focusing on other things: at least two developers are working on KDE integration, and a Debian developer at Collabora maintains the Flatpak package that is currently in Debian testing for release in Debian 9.0.
Re:Snaps are universal Linux packages by chriswarbo on Friday February 03, 2017 @02:38AM (#13558395)
> Snappy, FlatPak, and Nix need to install to a root directory

Not sure about Snappy and FlatPak, but Nix can use any directory as its "root"; users can run it from somewhere in their home directory without any need for admin rights.

The downsides to doing that, compared to a global /nix directory, are a) waste of disk space if multiple users have Nix running from their home directories and b) having to build stuff locally, since the official binary caches are built with /nix as the root.

Also, there are other distro-agnostic package managers like 0install, Autopackage and Listaller; packagekit is arguably related, as it provides a distro-agnostic abstraction layer; systemd's "portable services" are another recent addition to this space.

Re:Snaps are universal Linux packages by grhmc on Friday February 03, 2017 @11:48AM (#13561115)
I don't know of anyone running nix with the nix store being in their home directory, as it would require recompiling the entire world and receiving no benefit of the pre-built cache. Much more commonly the user will install a "single-user" mode nix, where the nix store is still located at `/nix/store` (in the root,) where it could possibly be that multiple users share it.
Re:Snaps are universal Linux packages by ghkbrew on Monday February 06, 2017 @05:06PM (#13584685)
It does seem to be much less common, but the home directory based nix install is extremely useful if you don't actually have admin rights on the machine. I.e. in basically any institutional system. I have a very handy nix install in my home directory on a university supercomputing cluster. As annoying as it is to have to compile everything it's much better than not having that software at all or having to go though the sys admins to maybe get something installed a month later.
Re:Snaps are universal Linux packages by ffuugoo on Thursday February 02, 2017 @11:48PM (#13557762)
I'd not compare Nix to other three. Yes, you are right, it is kind of "distro-agnostic/sandboxed/multiple-versions", it "need to install to a root directory" and does not "need a runtime daemon", but otherwise it is totally different and much more than others.
Re:Snaps are universal Linux packages by chriswarbo on Friday February 03, 2017 @12:05PM (#13561252)
I mostly agree, but there is a similarity in that the Nix build/CI server "Hydra" puts a "One click install" link on build outputs (e.g. http://hydra.nixos.org/build/47550492 )
Re:Snaps are universal Linux packages by makapuf on Friday February 03, 2017 @10:51AM (#13560607)
Haiku package manager really shines here, since you can directly run a package without installation, INCLUDING THE KERNEL.
Re:Snaps are universal Linux packages by jhasse on Friday February 03, 2017 @06:58AM (#13559183)
> FlatPak [..] need to install to a root directory

You can install flatpaks locally without root.

Re:Snaps are universal Linux packages by huevo5050 on Friday February 03, 2017 @02:12AM (#13558298)
What about Chef's Habitat [0], is playing the same league?

[0] http://habitat.sh