diff --git a/pkgs/build-support/fetch-node-modules.nix b/pkgs/build-support/fetch-node-modules.nix index 78899da..2376b6f 100644 --- a/pkgs/build-support/fetch-node-modules.nix +++ b/pkgs/build-support/fetch-node-modules.nix @@ -1,7 +1,7 @@ # This is a modified version of # https://github.com/NixOS/nixpkgs/pull/128749 -{ lib, stdenvNoCC, makeWrapper, nodejs }: +{ lib, stdenvNoCC, makeWrapper, nodejs, cacert }: { src , hash ? "" @@ -25,6 +25,9 @@ stdenvNoCC.mkDerivation ({ phases = "unpackPhase patchPhase buildPhase installPhase"; + # npm doesn't support var `SSL_CERT_FILE`. + NODE_EXTRA_CA_CERTS = "${cacert}/etc/ssl/certs/ca-bundle.crt"; + buildPhase = '' runHook preBuild