1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-08 19:23:54 +02:00

Allow non-CA derivations to depend on CA derivations

This commit is contained in:
regnat 2020-09-23 16:30:42 +02:00
parent e0ca98c207
commit c092fa4702
8 changed files with 124 additions and 23 deletions

View file

@ -15,7 +15,7 @@ rec {
'';
};
rootCA = mkDerivation {
name = "dependent";
name = "rootCA";
outputs = [ "out" "dev" ];
buildCommand = ''
echo "building a CA derivation"
@ -51,4 +51,13 @@ rec {
outputHashMode = "recursive";
outputHashAlgo = "sha256";
};
dependentNonCA = mkDerivation {
name = "dependent-non-ca";
buildCommand = ''
echo "Didn't cut-off"
echo "building dependent-non-ca"
mkdir -p $out
echo ${rootCA}/non-ca-hello > $out/dep
'';
};
}

View file

@ -22,6 +22,7 @@ secondSeedArgs=(-j0)
# dependent derivations always being already built.
#testDerivation dependentCA
testDerivation transitivelyDependentCA
testDerivation dependentNonCA
nix-instantiate --experimental-features ca-derivations ./content-addressed.nix -A rootCA --arg seed 5
nix-collect-garbage --experimental-features ca-derivations --option keep-derivations true