nix config to save some space

This commit is contained in:
Dennis Frieberg 2024-10-13 13:45:11 +02:00
parent e7154785dd
commit b2e5d28f2b
Signed by: nerf
GPG key ID: 7C58AFED036072C5
3 changed files with 28 additions and 15 deletions

View file

@ -5,18 +5,11 @@
}: {
imports = [
./admins.nix
./nix_keys.nix
./nix.nix
./prometheusNodeExporter.nix
../modules/impermanence.nix
];
nix = {
extraOptions = ''
experimental-features = nix-command flakes
builders-use-substitutes = true
'';
};
networking = {
firewall = {
# these shoud be default, but better make sure!

27
nixos/roles/nix.nix Normal file
View file

@ -0,0 +1,27 @@
{
nix = {
settings = {
trusted-public-keys = [
"nerflap2-1:pDZCg0oo9PxNQxwVSQSvycw7WXTl53PGvVeZWvxuqJc="
"gonne.mathebau.de-1:FsXFyFiBFE/JxC9MCkt/WuiXjx5dkRI9RXj0FxOQrV0="
];
experimental-features = [
"flakes"
"nix-command"
];
auto-optimise-store = true;
fallback = true;
builders-use-substitutes = true;
};
gc = {
persistent = true;
dates = "weekly";
options = "-d";
randomizedDelaySec = "5h";
};
optimise = {
dates = [];
automatic = true;
};
};
}

View file

@ -1,7 +0,0 @@
{
imports = [];
nix.settings.trusted-public-keys = [
"nerflap2-1:pDZCg0oo9PxNQxwVSQSvycw7WXTl53PGvVeZWvxuqJc="
"gonne.mathebau.de-1:FsXFyFiBFE/JxC9MCkt/WuiXjx5dkRI9RXj0FxOQrV0="
];
}