diff --git a/machines/nunotaba/configuration.nix b/machines/nunotaba/configuration.nix index f046ac8..d511032 100644 --- a/machines/nunotaba/configuration.nix +++ b/machines/nunotaba/configuration.nix @@ -4,13 +4,13 @@ imports = [ ./hardware-configuration.nix - ../../modules/cpu/intel.nix ../../modules ../../profiles/dev.nix ../../users/simon ]; sbruder = { + cpu.intel.enable = true; gpu.intel.enable = true; gui.enable = true; libvirt.enable = true; diff --git a/machines/sayuri/configuration.nix b/machines/sayuri/configuration.nix index 3d1b00d..7824f9e 100644 --- a/machines/sayuri/configuration.nix +++ b/machines/sayuri/configuration.nix @@ -4,13 +4,13 @@ imports = [ ./hardware-configuration.nix - ../../modules/cpu/intel.nix ../../modules ../../profiles/dev.nix ../../users/simon ]; sbruder = { + cpu.intel.enable = true; gpu.amd.enable = true; gui.enable = true; libvirt.enable = true; diff --git a/modules/cpu/default.nix b/modules/cpu/default.nix new file mode 100644 index 0000000..7934478 --- /dev/null +++ b/modules/cpu/default.nix @@ -0,0 +1,5 @@ +{ + imports = [ + ./intel.nix + ]; +} diff --git a/modules/cpu/intel.nix b/modules/cpu/intel.nix index ec52660..ed1efd4 100644 --- a/modules/cpu/intel.nix +++ b/modules/cpu/intel.nix @@ -1,3 +1,11 @@ +{ config, lib, ... }: +let + cfg = config.sbruder.cpu.intel; +in { - hardware.cpu.intel.updateMicrocode = true; + options.sbruder.cpu.intel.enable = lib.mkEnableOption "intel cpu configuration"; + + config = lib.mkIf cfg.enable { + hardware.cpu.intel.updateMicrocode = true; + }; } diff --git a/modules/default.nix b/modules/default.nix index df4734e..ba6cffe 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -10,6 +10,7 @@ # configuration options imports = [ ./communication.nix + ./cpu ./creative.nix ./cups.nix ./docker.nix