nixos: add preferLocalBuild=true; on derivations for config files

This commit is contained in:
Symphorien Gibol
2019-02-22 20:11:27 +01:00
committed by nix-review
parent 2a81eceeba
commit a915b33315
56 changed files with 99 additions and 60 deletions
@@ -217,7 +217,7 @@ let
) null ([ cfg ] ++ subservices);
documentRoot = if maybeDocumentRoot != null then maybeDocumentRoot else
pkgs.runCommand "empty" {} "mkdir -p $out";
pkgs.runCommand "empty" { preferLocalBuild = true; } "mkdir -p $out";
documentRootConf = ''
DocumentRoot "${documentRoot}"
@@ -426,6 +426,7 @@ let
phpIni = pkgs.runCommand "php.ini"
{ options = concatStringsSep "\n"
([ mainCfg.phpOptions ] ++ (map (svc: svc.phpOptions) allSubservices));
preferLocalBuild = true;
}
''
cat ${php}/etc/php.ini > $out
@@ -116,9 +116,10 @@ let
'';
};
mediawikiScripts = pkgs.runCommand "mediawiki-${config.id}-scripts"
{ buildInputs = [ pkgs.makeWrapper ]; }
''
mediawikiScripts = pkgs.runCommand "mediawiki-${config.id}-scripts" {
buildInputs = [ pkgs.makeWrapper ];
preferLocalBuild = true;
} ''
mkdir -p $out/bin
for i in changePassword.php createAndPromote.php userOptions.php edit.php nukePage.php update.php; do
makeWrapper ${php}/bin/php $out/bin/mediawiki-${config.id}-$(basename $i .php) \