[Nix] Add self-hosted nixos cache

This commit is contained in:
Antoine Viallon 2022-06-11 18:05:20 +02:00
parent c8552eb989
commit 83c6db86f7
Signed by: aviallon
GPG key ID: 186FC35EDEB25716

View file

@ -34,6 +34,9 @@ in
stalled-download-timeout = 20; stalled-download-timeout = 20;
}; };
nix.binaryCaches = mkBefore [ "https://nix-cache.lesviallon.fr" ];
nix.binaryCachePublicKeys = mkBefore [ "nix-cache.lesviallon.fr-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" ];
nix.buildCores = mkIf (generalCfg.cores != null) generalCfg.cores; nix.buildCores = mkIf (generalCfg.cores != null) generalCfg.cores;
nix.maxJobs = mkIf (generalCfg.cores != null) (math.log2 generalCfg.cores); nix.maxJobs = mkIf (generalCfg.cores != null) (math.log2 generalCfg.cores);