nix-serve should no longer use the default store. Move binaryCaches into the machine submodule.

This commit is contained in:
Kevin Baensch 2019-12-14 07:46:00 +01:00
parent 89debb2c37
commit 345c054448
3 changed files with 19 additions and 9 deletions

View file

@ -1,6 +1,8 @@
{ config, lib, ... }:
{
let
cfg = config.machine;
in {
nix = {
maxJobs = 4;
buildCores = 1;
@ -9,14 +11,12 @@
extraOptions = ''
build-timeout = 86400 # 24 hours
'';
binaryCachePublicKeys = [ (lib.fileContents "${config.machine.secretPath}/hydra_cache.pub") ];
binaryCachePublicKeys = [ (lib.fileContents "${cfg.secretPath}/hydra_cache.pub") ];
trustedBinaryCaches = [
"https://cache.nixos.org"
"https://cache.ophanim.de"
];
] ++ cfg.binaryCaches;
binaryCaches = [
"https://cache.nixos.org"
"https://cache.ophanim.de"
];
] ++ cfg.binaryCaches;
};
}