refactor nix settings

This commit is contained in:
steveej 2023-12-01 21:00:17 +01:00
parent d32cf7e7f8
commit 7a66eb1ef5
6 changed files with 57 additions and 30 deletions

View file

@ -0,0 +1,16 @@
{pkgs, ...}: {
nix.settings = {
substituters = [
"https://holochain-ci.cachix.org"
"https://holochain-ci-internal.cachix.org"
"https://cache.holo.host/"
];
trusted-public-keys = [
"holochain-ci.cachix.org-1:5IUSkZc0aoRS53rfkvH9Kid40NpyjwCMCzwRTXy+QN8="
"holochain-ci-internal.cachix.org-1:QvVsSrTiearCjrLTVtNtJOdQCDTseXh7UXUuSMx46NE="
"cache.holo.host-1:lNXIXtJgS9Iuw4Cu6X0HINLu9sTfcjEntnrgwMQIMcE="
"cache.holo.host-2:ZJCkX3AUYZ8soxTLfTb60g+F3MkWD7hkH9y8CgqwhDQ="
];
};
}

View 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;
};
};
}