diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2012-07-27T13·57-0400 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2012-07-27T13·57-0400 |
commit | 7f8e805c8ef2d7728648553de6b762964730a09a (patch) | |
tree | ca6b3ba6a57f98b7a3f5828df4bb4990e2360e4d /scripts/download-from-binary-cache.pl.in | |
parent | 67c6f3eded7dcb7c79243ed41f177c960f2b6aad (diff) |
download-from-binary-cache: Only use the default cache for /nix/store
Diffstat (limited to 'scripts/download-from-binary-cache.pl.in')
-rw-r--r-- | scripts/download-from-binary-cache.pl.in | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/download-from-binary-cache.pl.in b/scripts/download-from-binary-cache.pl.in index 10d0db9adbcf..93692240051d 100644 --- a/scripts/download-from-binary-cache.pl.in +++ b/scripts/download-from-binary-cache.pl.in @@ -13,7 +13,9 @@ use strict; Nix::Config::readConfig; my @binaryCacheUrls = map { s/\/+$//; $_ } split(/ /, - ($ENV{"NIX_BINARY_CACHES"} // $Nix::Config::config{"binary-caches"} // "http://nixos.org/binary-cache")); + ($ENV{"NIX_BINARY_CACHES"} + // $Nix::Config::config{"binary-caches"} + // ($Nix::Config::storeDir eq "/nix/store" ? "http://nixos.org/binary-cache" : ""))); my $maxParallelRequests = int($Nix::Config::config{"binary-caches-parallel-connections"} // 150); $maxParallelRequests = 1 if $maxParallelRequests < 1; |