aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2014-08-07 15:36:54 +0200
committerEelco Dolstra <eelco.dolstra@logicblox.com>2014-08-07 15:37:21 +0200
commit4a198dae746379effe04c19341f1d370461c71c7 (patch)
tree632f5b8e3a7ba8e0f76558eb774d4fc1cb0d655a /scripts
parent98873ff7defffda9166c88e4e7c318119ca5eccc (diff)
install-nix-from-closure.sh: Use https channel if possible
Diffstat (limited to 'scripts')
-rw-r--r--scripts/install-nix-from-closure.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/install-nix-from-closure.sh b/scripts/install-nix-from-closure.sh
index 0a2890eee..8aa227afa 100644
--- a/scripts/install-nix-from-closure.sh
+++ b/scripts/install-nix-from-closure.sh
@@ -73,7 +73,11 @@ fi
# Subscribe the user to the Nixpkgs channel and fetch it.
if ! $nix/bin/nix-channel --list | grep -q "^nixpkgs "; then
- $nix/bin/nix-channel --add http://nixos.org/channels/nixpkgs-unstable
+ if [ -n "$SSL_CERT_FILE" ]; then
+ $nix/bin/nix-channel --add https://nixos.org/channels/nixpkgs-unstable
+ else
+ $nix/bin/nix-channel --add http://nixos.org/channels/nixpkgs-unstable
+ fi
fi
$nix/bin/nix-channel --update nixpkgs