News for hackers. Stuff that matters.
Re:NixOS Is Not Reproducible by womfoo on Saturday October 26, 2024 @05:38AM (#41953702)
Can you recommend tools you prefer/use for achieving reproducibility/determinism?
Re:NixOS Is Not Reproducible by im3w1l on Saturday October 26, 2024 @06:30AM (#41953899)
I enjoyed thinking about the "how would I do it differently question", note would, as I have never actually tried it.

Maybe something like this? All packages are defined as a tuple (dependencies, dev dependencies, base image, command list, file list). Builds are done by loading the base image into a virtual machine, copying the dev dependencies into the vm, running the commands, and then pulling the listed files out into the host. All packages of a given OS edition would use the same base image, I suppose.

If a user wants to configure a package it will be done by putting a patch file in his configuration directory. The patch is applied to the built files.

Re:NixOS Is Not Reproducible by viraptor on Saturday October 26, 2024 @08:38AM (#41954389)
You're describing nixpkgs with an external builder in a VM. That's exactly what it would do. And that tuple is what nixpkgs packages really are (with some macros on top, but you're not forced to use them).
Re:NixOS Is Not Reproducible by im3w1l on Saturday October 26, 2024 @01:04PM (#41956050)
My impression of configuration in nix is that a lot of configuration that in any other distro would be handled by changing some /etc/file is instead done in a completely separate way by editing some nix file. So that's one user-visible way it differs from what I mentioned of using a patch for the /etc/file.

Some simple example I found just now:

https://unix.stackexchange.com/questions/489509/how-do-i-mod...

Re:NixOS Is Not Reproducible by viraptor on Saturday October 26, 2024 @03:06PM (#41956960)
There are patches which need to live in the repo by default anyway, so that's already supported, just not as random /etc location. https://github.com/NixOS/nixpkgs/tree/master/pkgs/by-name/aw...