summaryrefslogtreecommitdiff
path: root/guix/scripts/substitute-binary.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2014-10-09 13:38:16 +0200
committerLudovic Courtès <ludo@gnu.org>2014-10-09 23:51:19 +0200
commit4938b0eead9b1f34883c166a16c769a5db03edd9 (patch)
tree6dca363040a808a928086c927106dac177efd898 /guix/scripts/substitute-binary.scm
parent9176607ec4cffb85b46e71af49bbc8a330aec5c3 (diff)
substitute-binary: Ignore $GUIX_BINARY_SUBSTITUTE_URL.
* guix/scripts/substitute-binary.scm (%cache-url): Ignore the 'GUIX_BINARY_SUBSTITUTE_URL' environment variable. * test-env.in: Invoke 'guix-daemon' with '--substitute-urls'. * tests/substitute-binary.scm: Set '%cache-url' to the value of 'GUIX_BINARY_SUBSTITUTE_URL'.
Diffstat (limited to 'guix/scripts/substitute-binary.scm')
-rwxr-xr-xguix/scripts/substitute-binary.scm27
1 files changed, 13 insertions, 14 deletions
diff --git a/guix/scripts/substitute-binary.scm b/guix/scripts/substitute-binary.scm
index 7a286426a1..a2d0cab727 100755
--- a/guix/scripts/substitute-binary.scm
+++ b/guix/scripts/substitute-binary.scm
@@ -625,20 +625,19 @@ found."
(assoc-ref (daemon-options) option))
(define %cache-url
- (or (getenv "GUIX_BINARY_SUBSTITUTE_URL")
- (match (and=> (find-daemon-option "substitute-urls")
- string-tokenize)
- ((url)
- url)
- ((head tail ..1)
- ;; Currently we don't handle multiple substitute URLs.
- (warning (_ "these substitute URLs will not be used:~{ ~a~}~%")
- tail)
- head)
- (#f
- ;; This can only happen when this script is not invoked by the
- ;; daemon.
- "http://hydra.gnu.org"))))
+ (match (and=> (find-daemon-option "substitute-urls")
+ string-tokenize)
+ ((url)
+ url)
+ ((head tail ..1)
+ ;; Currently we don't handle multiple substitute URLs.
+ (warning (_ "these substitute URLs will not be used:~{ ~a~}~%")
+ tail)
+ head)
+ (#f
+ ;; This can only happen when this script is not invoked by the
+ ;; daemon.
+ "http://hydra.gnu.org")))
(define (guix-substitute-binary . args)
"Implement the build daemon's substituter protocol."