8 ms·
Graham here, CEO of DetSys. I'd be happy to answer any questions I can about the new installer and what we're up to!
by grhmc 4y ago
Graham here, CEO of DetSys. I'd be happy to answer any questions I can about the new installer and what we're up to!
- tikhonj 4y agoDoes it work on macOS? Edit: Oh, just saw the link to GitHub with the supported systems, missed that the first time I read the page.
- flexiondotorg 4y agoYes, macOS is supported. X86_64 and Apple Silicon
- nicce 4y agoThere are no binaries for every package in Apple Silicon (but there are many). Also, many Linux-purpose binaries install but they might not work after all. For example Buildah for Podman.
- pmarreck 4y agoThis looks good. I know I'm about to speak towards the OS version and not the Nix that can run atop other distros, but I definitely had some hiccups on the way to my NixOS-on-ZFS-root install (1), such as the configuration of the root user, whether to declaratively or dynamically configure non-root users and wifi networks (and having a working wifi driver that worked with my onboard chip to begin with... I truly believe that linux installs should not be expected to have to bootstrap via Ethernet at this point). Admittedly, a few of these things were due to not using the official GUI installer, but IMHO the commandline non-GUI install of NixOS should be as painless as possible as well. (1) https://openzfs.github.io/openzfs-docs/Getting%20Started/NixOS/Root%20on%20ZFS.html https://openzfs.github.io/openzfs-docs/Getting%20Started/Nix... Regarding your argument against Bash, isn't it true that this is just a different version of the same bootstrapping problem, and that downloading a temporary but specific Bash version would get around that? (I agree that working with Bash leaves a lot to be desired. But it's also more accessible to end-users to hack on, observe, and learn from, than a compiled Rust binary is. And tools like Copilot and ChatGPT and https://www.shellcheck.net/ https://www.shellcheck.net/ make working in Bash MUCH more painless, I've found.) Couple more questions: 1) Is your installer idempotent? (I think it is, since you track what's been done in a JSON structure; just confirming! If the JSON file is lost, are you still idempotent though? lol) 2) Are you a profitable company or just a group of Nix believers?
- deleted 4y ago[deleted]
- grhmc 4y agoWhew, let's go. On NixOS: I generally agree, though it can be tricky to get that done with NixOS. I bet we can make some inroads there. Easy questions: > idempotent It isn't currently idempotent, but we're working on "curing" which brings some idempotency to it, and allows for "rescuing" installations that aren't working correctly. Curing will also support creating a JSON document for installs that don't already have one. > profitable company or just a group of Nix believers We are a for-profit company, and we are a group of Nix believers :). Bash: Bash is really hard to get right, and really hard to make fast, and really hard to extend its featureset to more complicated use cases. We could "just" download a bash, but when we're trying to navigate disk encryption and APFS volumes and mounts ... it is quite a lot easier to write and test that code in a "bigger" language. Also note that it isn't just Bash that we'd need to download, but coreutils and other utilities that Bash is really built on top of. We tried to fix a pretty simple bug last year in the Bash installer, and it took two weeks to validate a relatively straightforward, one line change was valid on all the platforms we target.
- aidenn0 4y ago> Also note that it isn't just Bash that we'd need to download, but coreutils and other utilities that Bash is really built on top of. We tried to fix a pretty simple bug last year in the Bash installer, and it took two weeks to validate a relatively straightforward, one line change was valid on all the platforms we target. This clarifies a lot of what confused me in TFA. I maintained millions of lines of bash code, some of which is decades old and run into only a single bash incompatibility that wasn't fixable with shopt. On the other hand, incompatibilities in programs bash is running are rampant, particularly between GNU and non-GNU systems (and even within GNU there are more surprises than you might think). The phrase "different bash implementations" was a major red herring for figuring out what you were talking about.
- pmarreck 4y agoFollowup question then: Are you hiring? :) What type of work do you do? (is it "sysadmin-flavored," etc.?)
- rmorey 4y agoI have nix currently installed from the official installer in multi-user mode on macOS - I believe it works fine, would there be any benefit to me uninstalling and reinstalling via your installer? edit: i went ahead and uninstalled, and reinstalled via this, and WOW that was fast
- grhmc 4y agoI'm delighted to see your edit :). Our installer makes a few configuration choices that upstream doesn't, but the main driving goal for us is to be reliable, safe, and easy to undo.
- kirbyfan64sos 4y agoDoes the multi-user mode work on SELinux-enabled systems and, if not, is it possible to install in single-user mode? The default installer's multi-user mode doesn't work with SELinux enforcing (https://github.com/NixOS/nix/issues/2374 https://github.com/NixOS/nix/issues/2374), and I didn't see a flag for enabling single-user mode when I used `install --help`. (There are some projects to make SELinux support work like https://github.com/dnkmmr69420/nix-with-selinux https://github.com/dnkmmr69420/nix-with-selinux, but it's not clear to me if that would even work with this installer in particular.)
- Alekhine 4y agoI'm on Fedora and had to turn SELinux off to get nix to work properly.
- grhmc 4y agoI commented elsewhere in the thread, but we have an open issue for SELinux support: https://github.com/DeterminateSystems/nix-installer/issues/124 https://github.com/DeterminateSystems/nix-installer/issues/1.... Hopefully we can get that rolling soon.
- pxc 4y agoThis would be huge for making Nix viable at certain organizations, as I'm sure you already understand! I would love to just be able to point people at an installer like this for usage with SELinux.
- anon291 4y agoWhat do you see as the biggest roadblock for Nix and how do you intend to address it?
- SuperSandro2000 4y agoOne if the bigger issues right now are mass rebuilds and content agreed derivations hopefully address that at least partly. Sadly there is not much work happening on them lately.
- bokchoi 4y agoThank you, this is great! I love the focus on OSX support and on uninstalling. As a nix newbie, it can be difficult to resolve some issues and sometimes re-installing is the simplest option. Is the end result of installing via the bash install script and this new installer the same? Can I use the new tool to uninstall nix installed via the bash script?
- grhmc 4y agoThanks! The end result is not quite the same. For example, we turn on flakes, nix-command, and make a couple other minor tweaks to the Nix configuration to make what we think are user-friendly improvements. For example: https://github.com/DeterminateSystems/nix-installer/blob/main/src/action/common/place_nix_configuration.rs#L29-L39 https://github.com/DeterminateSystems/nix-installer/blob/mai... Our installer also supports some environments that the upstream installer has a harder time with. The new installer can't _yet_ uninstall a Nix installed from the upstream installer, but our upcoming work on "curing" will bring that.
- Laaas 4y agoI do wonder why auto-optimise-store isn't enabled by default. Is there a historical reason for it? Would Eelco accept a PR making it the default?
- bokchoi 4y agoOh and as long as you're being opinionated about installing and making it easy for newcomers, have you considered including an option to install home-manager and nix-darwin? My uneducated guess is they are typically used by folks on OSX.
- pxc 4y agoSetting those up is the hardest thing someone who knows nothing about Nix might otherwise want to do right at the beginning. Nix-Darwin OOTB would be absolutely killer imo, since it provides such a great experience once it's in place.
- JamesSwift 4y agoHave you used home-manager as well? Would be interested to hear your thoughts on the two, and what specifically makes nix-darwin so nice overall. I haven't used it before, just home-manager.
- pxc 4y agoI've played with Home Manager, but I've never really used it long term as much as I have Nix-Darwin. (I'm not super interested in HM's dotfile management features, since I already have tools I like for that.) What's nice about Nix-Darwin for me is mainly how NixOS-like it is. I like keeping its config under /etc and treating systems using it like NixOS. There are a few modules that I think are pretty impressive and atypical for the Nix world, like the Homebrew module. I'm not sure if HM has something comparable.
- JamesSwift 4y agoHomebrew is a big gap in home-manager. In fact, my current setup (and the most common I think) is to use homebrew for casks, home-manager for everything else (and I also do some Brewfile management with home-manager).
- 4y ago
- JamesSwift 4y agoAny thoughts on adding max-jobs/cores to the default config? I've always set mine to `max-jobs = auto` and `cores = (sysctl -n hw.ncpu)` on mac.
- SuperSandro2000 4y agoNix should use similar values already by default but if you are regularly build heavy builds those settings are not good enough and need tweaking.
- deleted 4y ago[deleted]
- Wowfunhappy 4y agoWhat is the minimum (ie, oldest) version of macOS the installer will work on?