summary refs log tree commit diff
path: root/pkgs/build-support/fetchurl/default.nix
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2013-02-06 15:15:28 +0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2013-02-06 15:15:28 +0100
commit04765da09a4355ee94a38a591f4e59a88f658f27 (patch)
tree19b628d92c236b89191bc6af1864188471dcf02c /pkgs/build-support/fetchurl/default.nix
parentf337ab4430e972c183ef9aa6c54275bf8c996ab2 (diff)
downloadnixlib-04765da09a4355ee94a38a591f4e59a88f658f27.tar
nixlib-04765da09a4355ee94a38a591f4e59a88f658f27.tar.gz
nixlib-04765da09a4355ee94a38a591f4e59a88f658f27.tar.bz2
nixlib-04765da09a4355ee94a38a591f4e59a88f658f27.tar.lz
nixlib-04765da09a4355ee94a38a591f4e59a88f658f27.tar.xz
nixlib-04765da09a4355ee94a38a591f4e59a88f658f27.tar.zst
nixlib-04765da09a4355ee94a38a591f4e59a88f658f27.zip
fetchurl: Don't wait too long for the hashed mirrors
If the hashed mirror (nixos.org/tarballs) doesn't respond in 15
seconds, give up and try the original URL.
Diffstat (limited to 'pkgs/build-support/fetchurl/default.nix')
-rw-r--r--pkgs/build-support/fetchurl/default.nix4
1 files changed, 4 insertions, 0 deletions
diff --git a/pkgs/build-support/fetchurl/default.nix b/pkgs/build-support/fetchurl/default.nix
index 02af2aaf5712..09816d9ba8e4 100644
--- a/pkgs/build-support/fetchurl/default.nix
+++ b/pkgs/build-support/fetchurl/default.nix
@@ -32,6 +32,10 @@ let
     # This variable allows the user to override hashedMirrors from the
     # command-line.
     "NIX_HASHED_MIRRORS"
+
+    # This variable allows overriding the timeout for connecting to
+    # the hashed mirrors.
+    "NIX_CONNECT_TIMEOUT"
   ] ++ (map (site: "NIX_MIRRORS_${site}") sites);
 
 in