-
-
Notifications
You must be signed in to change notification settings - Fork 15.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document pinning nixpkgs in manual #27994
Comments
Would you know how that compares to setting |
I think the solution in the issue description is the best way. I don't see any need to use |
For reference, and if it helps anyone, my source for setting Except that has a typo on the line (the fourth
Should be something like the following instead:
And also I think it should be |
I think ideally there'd be a |
@ocharles
|
So that would have been the |
@domenkozar I don't entirely understand your comment. Yes, it uses IFD and that results in multiple phases, but beyond that I haven't seen any problems. It's not like a command has to be ran multiple times. What is the main problem? |
I use that pattern all the time at work. I even proposed something to make it a bit smoother, but it didn't really go anywhere: #22058 I also don't use Edit: to elaborate, I want to be able to cache the exact nixpkgs tarball with a known output hash because many of my machines can't hit github.com, so |
@ocharles if Nix needs to download anything before evaluating |
Just tried @puffnfresh 's implementation today, seems to work. Only issue was an ergonomic one, I wasn't sure how to get the sha256 so I used |
@adelbertc For GitHub, |
Relevant: #21732 |
It's been done in https://nixos.wiki/wiki/How_to_fetch_Nixpkgs_with_an_empty_NIX_PATH |
I think that's fair enough, although it still seems to be an IFD under 1.11 |
Can the documentation be updated to show you to pin the same nixpkgs to both the I currently have something like:
But I if instead I was using |
I've heard from both @nuttycom and @cocreature that nixpkgs' documentation doesn't describe how to ensure reproducible derivations by pinning the version of nixpkgs.
My knowledge is that this is probably the best way to pin:
The text was updated successfully, but these errors were encountered: