split nix options into a module

This commit is contained in:
LavaDesu 2021-07-15 20:26:09 +07:00
parent ab6049f578
commit a5495be32b
Signed by: cilly
GPG key ID: 6500251E087653C9
2 changed files with 20 additions and 17 deletions

View file

@ -21,29 +21,13 @@
kernel kernel
kernel-winter kernel-winter
networking networking
nix
packages packages
security security
snapper snapper
../users/rin.nix ../users/rin.nix
]; ];
nix = rec {
package = pkgs.nixUnstable;
binaryCaches = [
"https://cache.nixos.org?priority=10"
"https://lava.cachix.org"
];
binaryCachePublicKeys = [
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"lava.cachix.org-1:8lTWI/3IKWHByzzYHZySunMPYs2eAJw2duL+uLZkSy0="
];
trustedBinaryCaches = binaryCaches;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
nixpkgs.config.allowUnfree = true;
i18n.defaultLocale = "en_GB.UTF-8"; i18n.defaultLocale = "en_GB.UTF-8";
} }

19
modules/system/nix.nix Normal file
View file

@ -0,0 +1,19 @@
{ config, pkgs, ... }: {
nix = rec {
package = pkgs.nixUnstable;
binaryCaches = [
"https://cache.nixos.org?priority=10"
"https://lava.cachix.org"
];
binaryCachePublicKeys = [
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"lava.cachix.org-1:8lTWI/3IKWHByzzYHZySunMPYs2eAJw2duL+uLZkSy0="
];
trustedBinaryCaches = binaryCaches;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
nixpkgs.config.allowUnfree = true;
}