Refactored boot
This commit is contained in:
parent
326be5ceee
commit
2d7868490c
|
@ -1,10 +0,0 @@
|
|||
{ config, lib, ... }: {
|
||||
boot = {
|
||||
# Enable bootloader & clear /tmp on boot.
|
||||
cleanTmpDir = true;
|
||||
loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
};
|
||||
};
|
||||
}
|
|
@ -13,7 +13,6 @@
|
|||
./system
|
||||
./applications
|
||||
# TODO Refactor everything after this.
|
||||
./boot.nix
|
||||
./cli.nix
|
||||
./fonts.nix
|
||||
./zfs.nix
|
||||
|
|
|
@ -5,7 +5,6 @@ in {
|
|||
imports = [
|
||||
../applications/firefox.nix
|
||||
../applications/nextcloud.nix
|
||||
../boot.nix
|
||||
../cli.nix
|
||||
../fonts.nix
|
||||
../system/gtk.nix
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{ config, lib, pkgs, modulesPath, ... }: {
|
||||
{ config, lib, pkgs, ... }: {
|
||||
imports = [ ./graphical.nix ];
|
||||
|
||||
this.systems.boot.enable = true;
|
||||
networking.networkmanager.enable = true;
|
||||
users.users.james.extraGroups = [ "networkmanager" ];
|
||||
}
|
||||
|
|
22
modules/system/boot.nix
Normal file
22
modules/system/boot.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
let cfg = config.this.systems.boot;
|
||||
in with lib; {
|
||||
options.this.systems.boot = {
|
||||
enable = mkOption {
|
||||
default = true;
|
||||
type = with types; bool;
|
||||
description = "Is there a physical power button?";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
boot = {
|
||||
# Enable bootloader & clear /tmp on boot.
|
||||
cleanTmpDir = true;
|
||||
loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1 +1,3 @@
|
|||
{ config, pkgs, ... }: { imports = [ ./gtk.nix ./xdg.nix ./flatpak.nix ]; }
|
||||
{ config, pkgs, ... }: {
|
||||
imports = [ ./gtk.nix ./boot.nix ./xdg.nix ./flatpak.nix ];
|
||||
}
|
||||
|
|
Reference in New Issue
Block a user