Skip to content

Commit 1644ca7

Browse files
rorosenpaschoal
authored andcommitted
k3s: use nurl instead of nix-prefetch in update script
The changes introduced with NixOS#354367 lead currently to an evaluation error when prefetching vendored go dependencies with `nix-prefetch`. Although this is probably a bug in `nix-prefetch`, I prefer to use `nurl` instead as it does the same thing, seems better maintained and doesn't block k3s updates even longer.
1 parent 0bc016e commit 1644ca7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkgs/applications/networking/cluster/k3s/update-script.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env nix-shell
2-
#!nix-shell -i bash -p curl gnugrep gnused jq yq-go nix-prefetch
2+
#!nix-shell -i bash -p curl gnugrep gnused jq nurl yq-go
33

44
set -x -eu -o pipefail
55

@@ -141,7 +141,7 @@ cat >versions.nix <<EOF
141141
EOF
142142

143143
set +e
144-
K3S_VENDOR_HASH=$(nix-prefetch -I nixpkgs=${NIXPKGS_ROOT} "{ sha256 }: (import ${NIXPKGS_ROOT}. {}).k3s_1_${MINOR_VERSION}.goModules.overrideAttrs (_: { vendorHash = sha256; })")
144+
K3S_VENDOR_HASH=$(nurl -e "(import ${NIXPKGS_ROOT}. {}).k3s_1_${MINOR_VERSION}.goModules")
145145
set -e
146146

147147
if [ -n "${K3S_VENDOR_HASH:-}" ]; then

0 commit comments

Comments
 (0)