diff options
author | Vladimír Čunát <v@cunat.cz> | 2019-05-09 09:49:42 +0200 |
---|---|---|
committer | Vladimír Čunát <v@cunat.cz> | 2019-05-09 09:49:42 +0200 |
commit | b27cc3767115bb8d93cc30b41be04621e4efb85f (patch) | |
tree | 40b67c7f03d94c54dcd6da9dbf48873a418f1d9c /pkgs/stdenv | |
parent | 79bd4ad5794163b8a65acc86809a6603ee7c7ce7 (diff) |
stdenv: also override cert files in pure nix-shell
That's very much consistent with the spirit of nix-shell --pure
BTW, nix 1.x shells will be always treated as pure;
in that version detection isn't possible.
https://github.com/NixOS/nix/commit/1bffd83e1a9c
Diffstat (limited to 'pkgs/stdenv')
-rw-r--r-- | pkgs/stdenv/generic/setup.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/pkgs/stdenv/generic/setup.sh b/pkgs/stdenv/generic/setup.sh index 9cc5cd89f3b7..dcccdaa50ae5 100644 --- a/pkgs/stdenv/generic/setup.sh +++ b/pkgs/stdenv/generic/setup.sh @@ -647,12 +647,12 @@ export NIX_BUILD_CORES # Prevent SSL libraries from using certificates in /etc/ssl, unless set explicitly. -# Leave it in shells for convenience. -if [ -z "${NIX_SSL_CERT_FILE:-}" ] && [ -z "${IN_NIX_SHELL:-}" ]; then +# Leave it in impure shells for convenience. +if [ -z "${NIX_SSL_CERT_FILE:-}" ] && [ "${IN_NIX_SHELL:-}" != "impure" ]; then export NIX_SSL_CERT_FILE=/no-cert-file.crt fi # Another variant left for compatibility. -if [ -z "${SSL_CERT_FILE:-}" ] && [ -z "${IN_NIX_SHELL:-}" ]; then +if [ -z "${SSL_CERT_FILE:-}" ] && [ "${IN_NIX_SHELL:-}" != "impure" ]; then export SSL_CERT_FILE=/no-cert-file.crt fi |