From 4e59f8c50154baaad2a8bb0a7ffc3c8bcfe0dcb6 Mon Sep 17 00:00:00 2001 From: derped Date: Wed, 2 Feb 2022 20:21:14 +0100 Subject: [PATCH] Some nix options have been renamed. --- config/nix.nix | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/config/nix.nix b/config/nix.nix index 15c0590..c1429be 100644 --- a/config/nix.nix +++ b/config/nix.nix @@ -4,22 +4,24 @@ let cfg = config.machine; in { nix = { - maxJobs = 4; - buildCores = 1; - autoOptimiseStore = true; - useSandbox = true; package = pkgs.nix_2_4; - allowedUsers = [ "root" ] ++ (map (n: n.name) cfg.administrators); + settings = { + max-jobs = 4; + cores = 1; + sandbox = true; + auto-optimise-store = true; + trusted-substituters = [ + "https://cache.nixos.org" + ] ++ cfg.binaryCaches; + trusted-public-keys = [ (lib.fileContents "${cfg.secretPath}/hydra_cache.pub") ]; + substituters = [ + "https://cache.nixos.org" + ] ++ cfg.binaryCaches; + allowed-users = [ "root" ] ++ (map (n: n.name) cfg.administrators); + }; extraOptions = '' build-timeout = 86400 # 24 hours experimental-features = nix-command flakes ''; - binaryCachePublicKeys = [ (lib.fileContents "${cfg.secretPath}/hydra_cache.pub") ]; - trustedBinaryCaches = [ - "https://cache.nixos.org" - ] ++ cfg.binaryCaches; - binaryCaches = [ - "https://cache.nixos.org" - ] ++ cfg.binaryCaches; }; }