Why all the NixOS hype? Did we all forget about Guix?
https://guix.gnu.org/en/manual/en/guix.html#Setting-Up-the-Daemon
https://guix.gnu.org/en/manual/en/guix.html#Setting-Up-the-Daemon
Also, I don't know who needs to read this but ChatGPT explains how to do things in Nix better than any Nix community member ever has for me. I can ask it "how do I create a directory with Nix" and it gives me the function and a practical example. It's great.
However, for setting up stuff in $HOME, there's a popular tool which uses the Nix expression language as its configuration language: home-manager. Even then, home-manager is more about using nix to configure programs. (I use it to symlink dotfiles). Nix's default is "the stuff it symlinks is read-only".
For "ensure this directory exists", I'd have `mkdir -p <dir you want>` in your shell's init / rc file.
I think the trouble is this:
Nix (or NixOS, really), on the surface, looks like a configuration management system and a packaging specification had a functional programming baby.
Now, I'm a systems engineer who generally writes in easy-to-use languages. I've used Arch the past decade and have used a variety of tools to automate my personal systems. My team is composed of systems administrators and network engineers who transitioned into devops-esque roles. Part of the purview of our jobs is to use configuration management systems to codify OS state. This could either result in an immutable image or mutable state on a long-running piece of field hardware.
Nix looks like a potential replacement for something like Ansible/Packer and there are a variety of projects hitting the front page of Hacker News that semi-presents it as a replacement (stuff like nix-ops or image to cloud pipelines).
So as someone who codifies system state as part of their day-to-day job, I'm looking at NixOS as a potential alternative. And there seems to be ABSOLUTELY no community support or documentation for learning Nix from a systems administrator point of view. Which is absolutely maddening because I'm an individual contributor that decides how packaging is done within a organization. Everybody in my team looked at Nix and said "this is absolutely impossible to use - we are literally never going to use this to support our organization."
And that's mostly because there is no guiding principle for how to adapt your mental model to think about the new paradigm if you're coming from something like Ansible... and there is no structured documentation for how to produce an OS state when what you know is YAML blocks or a Ruby based DSL.
I mean, it feels like the bones are there: you use Nix to install packages, start services, configure network interfaces, manage the kernel, etc.
But it also feels like Nix was built by functional programmers for functional programmers - with no UX for the people who would actually manage operating systems within a technical organization. Your syseng team isn't going to be functional programming whizzes. They're going to know Go or Python and be able to do medium-difficulty leetcode problems.
Honestly, there needs to be a "NixOS for Ansible Programmers." And if it's absolutely apples to oranges, then that needs to be communicated upfront somewhere.
[0] https://boilingsteam.com/how-i-built-my-new-linux-gaming-des...
[1] https://boilingsteam.com/i-love-arch-but-gnu-guix-is-my-new-...
Guix refuses to support any non FOSS hardware (like my MacBook) so that was a deal breaker for me.
Yes, Guix does not support non-Free software. However, nothing prevents you and others from supporting it. I'm fact, it can be and is distributed through channels. If I recall, this is the most prominent: https://gitlab.com/nonguix/nonguix
I’m saying I wanted to use Guix but I have MacBooks that I need to support, and Guix doesn’t support Darwin (the macOS system) so I went with Nix.
My bet is that the things that are difficult about Nix are difficult about Guix as well; whereas choice of language is cosmetic here.
My understanding is that before nix flakes, guix's CLI was much much nicer.
For me, the "free software absolutism" is a primary selling point. I don't use Nix because of that.
I've had mixed interactions with the Guix community from welcoming and helpful to arrogant and extremely rude. However, it's a community which is growing and was small for a long time. I see the lack of compassion as problems with individuals rather than the community. Leadership has changed and new organization is taking form. There has been tremendous growth the past year.
The documentation is hit or miss. Either it's great and you find your answer immediately or you find yourself in the weeds, digging through source code, guessing at what something means or guessing if something is Guix or Guile (and good luck with the Guile docs).
> Guix is an advanced distribution of the GNU operating system
This sounds like it competes (?) with NixOS, but not with Nix. A reason for the popularity of Nix is that it's not only an operating system. Most Nix users probably haven't touched NixOS, but they use Nix as a package manager, build system, development environment, etc on their local machine. That target audience is a lot larger than those who want to adopt a whole new operating system.
This adoption of Nix outside of the operating system context naturally leads to more adoption of NixOS. If you already work with Nix anyway, it's not that huge of a jump towards adopting NixOS.
> You can install GNU Guix on top of an existing GNU/Linux system where it complements the available tools without interference (see Installation), or you can use it as a standalone operating system distribution, Guix System2.
https://guix.gnu.org/en/manual/en/html_node/Introduction.htm...
I think my point about broader applicability still stands though. Compare the guix [0] and nix [1] homepages. The former mainly sells and operating system (and somewhat mentions a package manager), while the Nix homepage sells a tool, kind of like Docker, with concrete examples: Reproducible builds, trying new tools, declarative developer environments, docker images, cloud images. For a lot of people these are immediate practical use cases, which I think is the reason behind the adoption and hype.
I don't know anything about guix, so I'm not sure what of these you can do with guix, but at least the homepage and manual don't give me the impression that these are the use cases. I don't really need an additional package manger or a new OS, but the Nix use cases speak to me.
I don't want to use a project which is actively hostile to what I'm trying to do, even if there are workarounds. It just doesn't seem like a good idea long-term.
Like it or not, GNU is and always has been an important project for open source and user freedom
I'd say, though, that Nix has benefits above just package reproducibility.
e.g.:
> install Rust/node.js/Go/Java/C compiler once and forget about it.
And if you need dependency libraries, you copy-paste the `brew install` commands from the readme. And if different projects need different Node versions, you'd use NVM to manage those.
These problems are solvable and don't take much effort. (Well, for deploying code, it's difficult enough that Docker containers are as popular as they are).
With Nix, you can have a "put in effort now to save effort later". So you can get the above as "push of a button" without having to copy-paste the commands. -- I mean, that's a neat benefit, that's not really focused on "reproduce the exact behaviour".
> install and forget about it.
You are aware that problems don't just disappear when you forget, right?
https://gitlab.com/nonguix/nonguix
There are flatpacks, snaps, appimages, PPAs, channels... why would you except a linux distro maintainer to work for free for a billion dollar company? Testing and maintain their software
But Nix/NixOS provides me a better experiences because of those decisions and thus, is why I use it.
The basic installer is as simple as any other mostly point and click. If you already have your config file you can use it
In less than a week did all common stuff, with less effort than I would think for such a different distribution: install, move installation to a different drive and PC, chroot, fix grub and installation, use a custom kernel, create a custom packages, install packages from other people channels...
I don't particularly care lisp, I did mostly copy and paste with nano, later installed geany for matching parentheses
Their official documentation is very good
Has less packages but you can install Nix packages
Since Nix uses systemd I would say it would be easier drop in replacement for someone from Debian
Reached out briefly for help on the IRC with no response, same with the guix-help mailing list.
Guix seems really interesting, I'd like to learn some lisp, and I eventually even got an aarch64 Guix System VM running on my M1 Mac... but today I finally gave up and just installed NixOS on the same laptop (actually NIXOS_LUSTRATE over Arch on a BTRFS multi-subvol root). Went without a hitch.
My custom system description (https://paste.debian.net/hidden/78313f40) just blinks "error in service module" when I try to log in, which doesn't seem like a OOM issue, but who knows. I can't even log in in order to debug.
IRC (on libera) is pretty active, maybe try again.
I see your mail on help-guix[1], but there's no mention of sudo looking up the system. I'm not familiar enough with btrfs to help here, but there are many btrfs enthusiasts in the community, who could probably help you here.
[1]: https://lists.gnu.org/archive/html/help-guix/2022-12/msg0012...
Their work on bootstrapping is especially cool: https://news.ycombinator.com/item?id=18621393
Your attempt to set up "ideologically driven" as an obstacle to "general purpose" is baffling, because we've gone out of our way to make extending Guix close to trivial: via channels, through package transformations, by augmenting the Guile load path to load any modules you might have (with "-L", "GUIX_PACKAGE_PATH", or even just the Guile load path variables).
Ideology runs through the communities and development processes of all kinds of tools, including possible alternatives to Guix, like Nix. You can find many Nixpkgs PRs where reviewers are concerned with 'purity' in a technical sense, which is absolutely ideological even when it addresses really important concerns.
And similarly, Nix doesn't let you install non-free software by default, even though it includes the build recipes in Nixpkgs. Software freedom is important (surprise, surprise) to many free software developers, not just contributors to Guix or other GNU projects.
Guix should not be overlooked because of the project's political commitments. It's absolutely general-purpose software which can be used flexibly.
It's not directly related to this exact thread but I want to address the macOS question from a Nix perspective, since it has come up on this post and often comes up on others. macOS breaks Nix all the time, almost on every major OS update. It is a lot of work to keep things working nicely on macOS, and even though Nix's macOS support is really good, it's not as good as the Linux support. While I think that makes Nix accessible to many users in a way that is great, it's totally understandable that Guix currently faces a chicken-and-egg problem in terms of developer interest in supporting macOS— if you don't already use, know, and like macOS, trying to port Guix to it and maintain that support seems daunting and pretty unattractive. I wouldn't want to be responsible for supporting either package manager on macOS.
And I don't think that has anything to do with 'extreme' developer ideology! It's just about the ordinary problem of developer interest and volunteer projects.