* Set preferLocalBuild on a few trivial top-level derivations. These

tend to cause a lot of unnecessary I/O to the build machines.

svn path=/nixos/trunk/; revision=33936
This commit is contained in:
Eelco Dolstra 2012-04-26 15:19:23 +00:00
parent 836fa3b6ae
commit 03f2847054
3 changed files with 4 additions and 2 deletions

View File

@ -147,6 +147,7 @@ let
# and makes it bootable.
system = pkgs.stdenv.mkDerivation {
name = "nixos-${config.system.nixosVersion}";
preferLocalBuild = true;
buildCommand = systemBuilder;
inherit children;
kernelParams =

View File

@ -135,7 +135,7 @@ let
in
pkgs.runCommand ("upstart-" + job.name + ".conf")
{ inherit (job) buildHook; inherit jobText; }
{ inherit (job) buildHook; inherit jobText; preferLocalBuild = true; }
''
eval "$buildHook"
echo "$jobText" > $out

View File

@ -184,6 +184,7 @@ let
{ exportReferencesGraph =
map (x: [("closure-" + baseNameOf x) x]) config.virtualisation.pathsInNixDB;
buildInputs = [ pkgs.perl ];
preferLocalBuild = true;
}
''
printRegistration=1 perl ${pkgs.pathsFromGraph} closure-* > $out
@ -353,7 +354,7 @@ in
# Don't run ntpd in the guest. It should get the correct time from KVM.
services.ntp.enable = false;
system.build.vm = pkgs.runCommand "nixos-vm" {}
system.build.vm = pkgs.runCommand "nixos-vm" { preferLocalBuild = true; }
''
ensureDir $out/bin
ln -s ${config.system.build.toplevel} $out/system