refactor(modules/hardware): move hardware config to modules
This commit is contained in:
parent
cb01ba95b0
commit
067e0c9970
7 changed files with 40 additions and 10 deletions
12
modules/nixos/system/boot.nix
Normal file
12
modules/nixos/system/boot.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{ config, lib, ... }:
|
||||
{
|
||||
config = lib.mkMerge [
|
||||
{
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
}
|
||||
(lib.mkIf (config.system.bootloader == "systemd-boot"){
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
})
|
||||
];
|
||||
}
|
|
@ -1,6 +1,7 @@
|
|||
{ config, lib, ...}:
|
||||
{
|
||||
imports = [
|
||||
./boot.nix
|
||||
./users.nix
|
||||
./localisation.nix
|
||||
./nix-config.nix
|
||||
|
@ -8,6 +9,7 @@
|
|||
|
||||
options.system = {
|
||||
mainUser = lib.pantheon.mkStrOption;
|
||||
bootloader = lib.pantheon.mkStrOption;
|
||||
};
|
||||
|
||||
config = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue