Files
nixos-template-base/configuration/nix-options.nix

24 lines
461 B
Nix
Raw Normal View History

2016-08-08 22:58:30 +02:00
{ config, lib, pkgs, ... }:
2016-07-22 14:16:20 +02:00
let
2016-08-12 12:46:36 +02:00
inherit (lib) mkIf mkMerge mkThenElse;
annuaire = config.r6d.machines;
currentMachine = annuaire."${config.networking.fqdn}";
flags = currentMachine.configurationFlags;
2016-08-08 22:58:30 +02:00
in
{
2016-08-12 12:46:36 +02:00
# Automatic update & automatic clean
system.autoUpgrade.enable = flags.auto-upgrade;
nix = {
autoOptimiseStore = true;
gc = {
automatic = true;
dates = "daily";
options = "--delete-older-than 7d";
};
};
}