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
busybox: Fix 404 error by using git instead #97894
Conversation
CC: @worldofpeace |
debianSource = fetchgit { | ||
url = "https://salsa.debian.org/installer-team/busybox.git"; | ||
rev = "debian/1%${debianVersion}"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using fetchFromGitLab is preferred. (I did not touch the hash, it probably needs to be updated too).
debianSource = fetchgit { | |
url = "https://salsa.debian.org/installer-team/busybox.git"; | |
rev = "debian/1%${debianVersion}"; | |
debianSource = fetchFromGitLab { | |
domain = "salsa.debian.org"; | |
owner = "installer-team"; | |
repo = pname; | |
rev = "debian/1%${debianVersion}"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fetchFromGitlab
does not currently work when the revision contains a slash, as the line renamed="$TMPDIR/${baseNameOf url}"
does not work as expected.
@@ -1,4 +1,4 @@ | |||
{ stdenv, lib, buildPackages, fetchurl, fetchzip | |||
{ stdenv, lib, buildPackages, fetchurl, fetchgit |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{ stdenv, lib, buildPackages, fetchurl, fetchgit | |
{ stdenv, lib, buildPackages, fetchurl, fetchFromGitLab |
see the other suggested change
d19277c
to
095261f
Compare
Debian has yanked the upstream tarball we use to get default.script. We could simply bump the version number to get the new tarball, but to avoid the problem in the future, we should instead fetch it from git.
095261f
to
a9597f9
Compare
@prusnak Please take another look. I had to update |
Why not fetch just the individual file instead of downloading the whole repo? |
@pbogdan I have no idea if the individual file download links are stable in gitlab. It seems like I could potentially use https://salsa.debian.org/installer-team/busybox/-/raw/debian/1%251.30.1-6/debian/tree/busybox-udeb/etc/udhcpc/default.script What do you think? Should I try to use that instead? |
@pbogdan If you are okay with this, I would prefer to get it merged as-is. I am getting a bit tired of bikeshedding how to get this file, since I have already tried four different methods for based on reiews (inlining the file in the nixpkgs repo, downloading from a debian tarball, downloading using |
Yeah, I'm not going to ask anyone to change anything again to get one file. Though I will say that if you're using github or gitlab, it will always be better to use the |
I think a backport for this is needed to 20.09? |
Done in #97929 |
Motivation for this change
Same motivation as for #97286: The current master is broken, as debian has yanked an upstream tarball, which we need to get
default.script
.This PR solves the issue by getting the file from git instead.
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)