-
-
Notifications
You must be signed in to change notification settings - Fork 16.4k
fetchurl: don't prefer hashed mirrors by default #405149
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
Conversation
Right now, when building any FOD that uses `fetchurl` (which is the majority of ours), `tarballs.nixos.org` will always be contacted before the actual URL. Given that `tarballs.nixos.org` mainly hosts the bootstrap tools, which already explicitly set it as the host to pull from, it doesn't make much sense to force every other `fetchurl` invocation to first reach out to `tarballs.nixos.org`.
@ofborg build tests.fetchurl |
Is there a report or logs from the infra team we could use to track the positive impact on t.n.o of this PR? |
I doubt it (nor do I really think it’d be worth the time/effort to pull), but cc @mweinelt |
We have some data that we used to grab from fastly, who handle the reverse proxying and caching for us. Currently fetching that data is in limbo. We need to finish NixOS/infra#388 on the infra side to make this data available again. |
Objections to backporting? TBH I wouldn’t consider this a breaking change, as it’ll still fetch from t.n.o if it can’t reach the specified host (and if anything was relying on this behavior by putting a bogus/incorrect URL in, that’s a bug). |
Going to land now, but would appreciate some opinions on backporting. (@mweinelt said yes to me on Matrix, at least.) |
Successfully created backport PR for |
@winterqt We hit this change internally and just wanted to share a data point. For some context, we host our internal Nix cache so we don't benefit from Sometimes the contents of the URL changes in a way (say GitHub changes After this change, we're left with either modifying the FOD hash or maintaining a patch reverting this change. In a way this was a breaking change for us, but I understand we may be a bespoke usecase. |
Right now, when building any FOD that uses
fetchurl
(which is the majority of ours),tarballs.nixos.org
will always be contacted before the actual URL. Given thattarballs.nixos.org
mainly hosts the bootstrap tools, which already explicitly set it as the host to pull from, it doesn't make much sense to force every otherfetchurl
invocation to first reach out totarballs.nixos.org
.Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.