hackens-org-configurations/machines/hackens-milieu/shared-hackens/system.nix
2024-01-12 16:19:31 +01:00

41 lines
865 B
Nix

{ pkgs, ... }: {
# Upgrades
system.autoUpgrade = {
enable = true;
allowReboot = false;
};
# SSD stuff
services.fstrim = {
enable = true;
};
# Auto-GC and store optimizations
nix = {
trustedUsers = [ "root" "hackens" ];
package = pkgs.nixUnstable;
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 60d";
};
optimise.automatic = true;
extraOptions = ''
experimental-features = nix-command flakes
# Thank you
min-free = ${toString (100 * 1024 * 1024)}
max-free = ${toString (1024 * 1024 * 1024)}
'';
};
services.locate.enable = true;
# ssh
services.openssh.enable = true;
services.openssh.passwordAuthentication = false;
# We are on a trusted network
networking.firewall.enable = false;
documentation.info.enable = false;
}