this post was submitted on 03 Nov 2023
440 points (93.5% liked)

linuxmemes

20756 readers
275 users here now

I use Arch btw


Sister communities:

Community rules

  1. Follow the site-wide rules and code of conduct
  2. Be civil
  3. Post Linux-related content
  4. No recent reposts

Please report posts and comments that break these rules!

founded 1 year ago
MODERATORS
 
all 44 comments
sorted by: hot top controversial new old
[–] stepanzak@iusearchlinux.fyi 92 points 10 months ago (3 children)

Why not? It always seemed to me like a lot of duplicated work to package everything on every distro.

[–] Chewy7324@discuss.tchncs.de 37 points 10 months ago (3 children)

Yes, but each package manager has it's (dis-)advantages. It's great to have flatpak and docker to be able to run software on almost all distros, but the OS still needs a way to update.

Almost all immutable distros use multiple package manager.

  • Fedora Silverblue: rpm-ostree + flatpak (+ toolbox)
  • OpenSUSE MicroOS: zypper with snapshots (transactional-update) + flatpak (+ distrobox)
  • NixOS is unique since it only uses the Nix package manager
  • immutable Ubuntu will probably only use snap for OS + apps.

All those OS support distrobox and docker additionally.

[–] monk@lemmy.unboiled.info 15 points 10 months ago (1 children)

NixOS is unique because it uses the only potent package manager (if we don't count that one reimplementation of Nix). Calling the others "package managers" becomes mostly a courtesy when NixOS enters the picture.

lalala with FS-level snapshots + flatpak + distrobox + a kitchen sink

look_what_they_need_to_mimic_the_fraction_of_our_power.png

[–] GuybrushThreepwo0d@programming.dev 11 points 10 months ago (3 children)

I don't consider myself a dumb person but I couldn't figure out nix when last I decided to play with it. Theoretically it seems super interesting to me, but I really just can't dedicate the time again now to learn that esoteric syntax.

[–] Chewy7324@discuss.tchncs.de 15 points 10 months ago (1 children)

The docs for NixOS aren't good. Much knowledge is on many blogs but who knows them all?

Having the OS defined declaratively is great but I also dislike the Nix language.

Once it's setup NixOS is great. Sharing configs with PC and laptop is awesome. Rollbacks are baked in.

Going off the https://github.com/Misterio77/nix-starter-configs helped me gettung started.

[–] silicon_reverie@lemmy.world 7 points 10 months ago* (last edited 10 months ago) (2 children)

I absolutely loved NixOS on paper, and it's undoubtedly the best way to combat updates that break my dependency trees, but I still found myself spending a majority of my time attempting to hard-code various app configuration files into my convoluted configuration.nix with its esoteric syntax rather than actually using my computer. Am I missing something, or does a good install script covering my favorite packages and a git bare repo storing my dot-files get me 90% of the way there without the hassle of bending my whole OS around a single nix config monstrosity?

[–] monk@lemmy.unboiled.info 1 points 10 months ago

Only if you reinstall every time you change the configuration. And never need to do anything remotely fancy.

[–] Chewy7324@discuss.tchncs.de 1 points 10 months ago

Agreed, I'm also considering switching to an install script + btrfs snapshots. It worked quite well a few years ago, altough it doesn't solve configuration drift.

[–] mac@infosec.pub 1 points 8 months ago

I found zero to nix to be a good tutorial

[–] monk@lemmy.unboiled.info 1 points 10 months ago

The syntax is just the outer layer, the whole concept inside it is alien. It's like a smartphone for a person who's only seen books.

[–] pimeys@lemmy.nauk.io 2 points 10 months ago (2 children)

You can use at least appimage with NixOS...

[–] monk@lemmy.unboiled.info 11 points 10 months ago

You cah also tow a Tesla with a couple of horses

[–] null@slrpnk.net 3 points 10 months ago

And flatpak

[–] merthyr1831@lemmy.world 1 points 10 months ago

all the more reason to sunlight these old packaging formats and move to universal solutions like flatpak and nix

[–] Synthead@lemmy.world 17 points 10 months ago (2 children)

Linked dependencies, for one. What if your distro uses uClibc? A different imagemagick version? What about LTS distros? Immutable distros?

[–] MrSpArkle@lemmy.ca 27 points 10 months ago (1 children)

What if who cares?

When I used to build app packages internally I also built packages for our own python and ruby versions for our in-house software. The motto was: “system packages are for system software”. We weren’t writing system software, we were writing business software and shipping it, so why be dependent on what Redhat or Debian provided?

Universal packages are just an extension of this philosophy, and is why things like docker and app stores are such a success. Burdening the user with getting system dependencies right is worse than the DLL hell of the old windows days.

[–] Synthead@lemmy.world 8 points 10 months ago (1 children)

Docker is a success in some ways, but it's not a silver bullet. It's a great way to make a 800 KiB program ship in a complex 300 MiB box.

If you had an entire operating system built with static links, it would be giant and ugly. You have to stop and think: if it's such a great idea, then why does pretty much every distro supply packages with dynamic links?

When shipping your own software, yes, you certainly want control over your own runtime. If you rely on an OS-supplied Ruby, for example, then when Ruby 3.3.0 comes out, your gems will need to be rebuilt, and it'll happen by surprise. A runtime and shipping stuff to your own infra is much different than packages responsible for running the operating system.

[–] theneverfox@pawb.social 2 points 10 months ago

It's almost a silver bullet. 300mb is pretty modest by today's standards, and nix supports both bare metal and docker containers, and everything in between

Seems to me we need to bridge that gap - make nix smarter and more compatible with docker, and we get a fully featured desktop/dev environment that can be packaged directly into the minimal reproducible deployment package

And that sounds like a silver bullet to me

[–] Chewy7324@discuss.tchncs.de 3 points 10 months ago

Usually people mean flatpak and other desktop-focused formats when talking about universal package formats.

Even docker images are usually built with traditionial package managers, except if they're built directly by Nix.

I agree that there won't be "the" package format, since they all have their tradeoffs. E.g. Nix updates need quite a bit of memory, so it isn't a good choice for resource constrained embedded use-cases.

[–] djsaskdja@reddthat.com 39 points 10 months ago

Flatpak seems quite nice now days

[–] possiblylinux127@lemmy.zip 23 points 10 months ago

Fine. You can do what you want but for me personally I will just use flatpak.

[–] umbrella@lemmy.ml 19 points 10 months ago* (last edited 10 months ago)

bad take, from a user AND developer standpoint

[–] Perroboc@lemmy.world 14 points 10 months ago (2 children)
[–] mariusafa@lemmy.sdf.org 5 points 10 months ago

Hey that's pretty good, thanks!

[–] ledtasso@lemmy.world 1 points 10 months ago* (last edited 10 months ago)

Is it used for any serious apps? I saw they released the "cosmos" which is very impressive but mostly seemed like basic utils that were already available in Linux/Mac?

[–] IverCoder@lemm.ee 12 points 10 months ago* (last edited 10 months ago) (1 children)

This isbessential for the year of the Linux desktop to come.

[–] ReginaPhalange@lemmy.world 5 points 10 months ago (1 children)

50 years and counting.
Any day now...

[–] AlijahTheMediocre@lemmy.world 1 points 10 months ago

32 years, Linux ain't THAT old

[–] Shatur@lemmy.ml 9 points 10 months ago* (last edited 10 months ago)

I see how it can be convenient for some distros to get the latest version or install something that is not in the official repo.

But I use ArchLinux and we always have latest versions and big repo + AUR, so I never used universal packages.

[–] AlmightySnoo@lemmy.world 8 points 10 months ago (1 children)
[–] lnee@lemm.ee 6 points 10 months ago (1 children)

laughs in immediate firefox updates

[–] Gentoo1337@sh.itjust.works 2 points 10 months ago (1 children)
[–] lnee@lemm.ee 0 points 10 months ago

laughs in snapd

[–] twelvefloatinghands@lemmy.world 7 points 10 months ago

I nominate nix