NixOS-PVE-Deployment-Util/nix-config/configuration.nix

42 lines
850 B
Nix
Raw Permalink Normal View History

{ modulesPath, config, pkgs, ... }:
{
imports = [
./lxc.nix
./users.nix
./network.nix
];
# Nix settings
nix = {
settings = {
auto-optimise-store = true;
experimental-features = [ "nix-command" "flakes" ];
allowed-users = [ "@wheel" ];
};
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 30d";
};
};
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# Set NIX_PATH
nix.nixPath = [
"nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixos"
"nixos-config=/etc/nixos/configuration.nix"
"/nix/var/nix/profiles/per-user/root/channels"
];
# Auto upgrades
system.autoUpgrade = {
enable = true;
dates = "04:00";
randomizedDelaySec = "45min";
persistent = true;
};
system.stateVersion = "24.05";
}