refactor nix settings
This commit is contained in:
parent
d32cf7e7f8
commit
7a66eb1ef5
6 changed files with 57 additions and 30 deletions
35
nix/os/snippets/nix-settings.nix
Normal file
35
nix/os/snippets/nix-settings.nix
Normal file
|
@ -0,0 +1,35 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
nix.daemonCPUSchedPolicy = "idle";
|
||||
nix.daemonIOSchedClass = "idle";
|
||||
nix.settings.max-jobs = lib.mkDefault "auto";
|
||||
nix.settings.cores = lib.mkDefault 0;
|
||||
nix.settings.sandbox = true;
|
||||
nix.nixPath = [
|
||||
"nixpkgs=${pkgs.path}"
|
||||
];
|
||||
|
||||
nix.experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
"ca-derivations"
|
||||
"impure-derivations"
|
||||
];
|
||||
|
||||
nix.system-features = [
|
||||
"recursive-nix"
|
||||
"big-parallel"
|
||||
"kvm"
|
||||
"nixos-test"
|
||||
];
|
||||
|
||||
nix.registry = {
|
||||
nixpkgs.to = {
|
||||
type = "path";
|
||||
path = pkgs.path;
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue