os/modules/core/nix.nix
teutat3s e2614c54f2
Some checks failed
continuous-integration/drone/push Build is passing
continuous-integration/drone/pr Build is failing
cachix: default binary cache is nixos.org, no need
to specify it explicitly (results in double entry in nix.conf)

Also force our nix.extraOptions because digga tries real hard to put
their binary caches there:
0595ae70cd/modules/nix-config.nix (L19-L23)
2023-03-27 18:08:01 +02:00

32 lines
766 B
Nix

{
config,
pkgs,
lib,
inputs,
...
}: {
nix = {
# Use default version alias for nix package
package = pkgs.nix;
gc.automatic = true;
optimise.automatic = true;
settings = {
# Improve nix store disk usage
auto-optimise-store = true;
# Prevents impurities in builds
sandbox = true;
# give root and @wheel special privileges with nix
trusted-users = ["root" "@wheel"];
# This is just a representation of the nix default
system-features = ["nixos-test" "benchmark" "big-parallel" "kvm"];
};
# Generally useful nix option defaults
extraOptions = lib.mkForce ''
min-free = 536870912
keep-outputs = true
keep-derivations = true
fallback = true
'';
};
}