Live data from Hacker News

NixOS: Declarative Builds and Deployments

nixos.org

31–40 of 83 posts

Re: NixOS: Declarative Builds and Deployments

#31
I'll be honest, the first few times I tried using Nix I just couldn't get into. It was too complex for the benefits I was getting. But that was using Nix on another OS.

I recently switched to NixOS because I wanted what they were selling and the experience this time around was way better. Having no other option but to figure it out made me learn the essentials real quick (like an exchange program to a foreign country that speaks another language).

If you think about it, when you used Ubuntu or Fedora or RHEL for the first time, and probably for a very long time, you could get by without learning the deep intricacies of what is going on behind the scenes. The same is true with NixOS. The things you need to learn are different, but once you get a basic setup with home-manager setup you're off to the races. (Btw, I used this "book" to get started and it was great: https://nixos-and-flakes.thiscute.world/)

The best part about using NixOS so far is that things just work. Setting up my graphics card was as simple setting enabled = true. Same for configuring specific audio frameworks. And I had tried many times to get Davinci Resolve working on other distros and always encountered issues leading me to need to dual-boot Windows so I could do video editing. Now I just enabled Davinci Resolve and it works! No more Windows.

If you're brand new to linux on the desktop, I wouldn't recommend it. But if you've been doing that for years, maybe try NixOS in 2024.

Re: NixOS: Declarative Builds and Deployments

#32
post #23

NixOS is honestly the single most game-changing thing I've been introduced to in my last decade of experience in tech. If you're interested in trying out NixOS I highly recommend either running it as an WSL2 VM[1] if you have a Windows machine or deploying it on a cheap VPS[2] to play around with. I personally still use a Win11 desktop for compat with Adobe software and a few other bits and pieces, but I do all my se…

I keep seeing this from people online but I have yet to see Nix in the wild at any large organization. For such a "game-changing" thing, it certainly doesn't have the meat space following you see online. To me, I tried Nix, got frustrated with packages, realized I'm just using someone else's abstractions for defining configuration files (with the same kind of quality you'd find on Ansible galaxy), and realized it's n…

Is Google large enough?

https://idx.dev/blog/post/nix-in-the-wild-project-idx

Re: NixOS: Declarative Builds and Deployments

#33

Honestly, I don’t really understand the advantages (or the point of) NixOS over something like Docker.

Better composability and abstraction, see for example how you can configure a process in https://devenv.sh/services/ that has first-class support for development environments using Nix. No need to use containers too, which bring cognitive/workflow overhead.

And Nix doesn't? At least with Docker you can get something useful within 2 minutes

Re: NixOS: Declarative Builds and Deployments

#34
post #22

I think the idea is good but execution is poor to reach mass adoption because: 1. It tries to replace ALL package managers due its extreme philosophy. I had a lot of issues when it tries to replace Cargo for example 2. It uses a functional language, which will lose 95% of users 3. It never had a great user experience especially if you’re new and trying to learn or if you’re not using linux or if you bring your own to…

I don't think points 1 and 2 are really that valid, but 3 is why I'm a Nix hater. They've managed to design an arcane solution to an everyday problem.

Nix solves real problems that Cargo can't/won't. And the 95% use case worth optimizing for isn't someone authoring flakes, but people just looking for the proper incantation to get the software they need for their environment.

Re: NixOS: Declarative Builds and Deployments

#35
post #22

I think the idea is good but execution is poor to reach mass adoption because: 1. It tries to replace ALL package managers due its extreme philosophy. I had a lot of issues when it tries to replace Cargo for example 2. It uses a functional language, which will lose 95% of users 3. It never had a great user experience especially if you’re new and trying to learn or if you’re not using linux or if you bring your own to…

nix is so powerful precisely because it takes a pure functional approach. You don’t get that level of reproducibility if you allow side effects.

Re: NixOS: Declarative Builds and Deployments

#37
post #22

I think the idea is good but execution is poor to reach mass adoption because: 1. It tries to replace ALL package managers due its extreme philosophy. I had a lot of issues when it tries to replace Cargo for example 2. It uses a functional language, which will lose 95% of users 3. It never had a great user experience especially if you’re new and trying to learn or if you’re not using linux or if you bring your own to…

I need to do some reading up on Nix, because I don't think I understand it. I thought NixOS was an operating system and Nix an operating system-level package manager, so why is it trying to replace Cargo, a package manager for a specific programming language in Rust?

Re: NixOS: Declarative Builds and Deployments

#38

Earlier quoted context omitted.

I keep seeing this from people online but I have yet to see Nix in the wild at any large organization. For such a "game-changing" thing, it certainly doesn't have the meat space following you see online. To me, I tried Nix, got frustrated with packages, realized I'm just using someone else's abstractions for defining configuration files (with the same kind of quality you'd find on Ansible galaxy), and realized it's n…

Is Google large enough? https://idx.dev/blog/post/nix-in-the-wild-project-idx

Nice, I didn't know this! I'll add that I know Nix is also used widely at Discord.

Re: NixOS: Declarative Builds and Deployments

#39
post #35
post #22

I think the idea is good but execution is poor to reach mass adoption because: 1. It tries to replace ALL package managers due its extreme philosophy. I had a lot of issues when it tries to replace Cargo for example 2. It uses a functional language, which will lose 95% of users 3. It never had a great user experience especially if you’re new and trying to learn or if you’re not using linux or if you bring your own to…

nix is so powerful precisely because it takes a pure functional approach. You don’t get that level of reproducibility if you allow side effects.

Avoiding side effects does not require inventing a brand new purely functional language programming language.

Re: NixOS: Declarative Builds and Deployments

#40
post #22

I think the idea is good but execution is poor to reach mass adoption because: 1. It tries to replace ALL package managers due its extreme philosophy. I had a lot of issues when it tries to replace Cargo for example 2. It uses a functional language, which will lose 95% of users 3. It never had a great user experience especially if you’re new and trying to learn or if you’re not using linux or if you bring your own to…

If you don't want to fully commit to the OS or the Package Manager, you can use Nixpkgs alongside your OS and other package managers by installing Nixpkgs on your Mac or Linux OS.

For the functional language and UX, I agree there's room for improvement. If you don't want to dive into learning Nix, you could use a wrapper that simplifies the UX for creating projects. We built one called Devbox (https://jetpack.io/devbox), which uses JSON for it's config format and has a CLI inspired by more familiar tools like Yarn.

Post reply on HN