diff --git a/hosts/desktop/default.nix b/hosts/desktop/default.nix index d6bf113..82d247b 100644 --- a/hosts/desktop/default.nix +++ b/hosts/desktop/default.nix @@ -6,24 +6,6 @@ nix-leonhard.graphical.enable = true; nix-leonhard.neovim.enable = true; - # Enable CUPS to print documents. - #services.printing.enable = true; - - # Enable firmware - #hardware.enableAllFirmware = true; - - # Enable bluetooth - #hardware.bluetooth.enable = true; - - # Enable sound with pipewire. - # security.rtkit.enable = true; - # services.pipewire = { - # enable = true; - # alsa.enable = true; - # alsa.support32Bit = true; - # pulse.enable = true; - # }; - users.users = { leonhard = { initialPassword = "leonhard"; diff --git a/hosts/desktop/hardware-configuration.nix b/hosts/desktop/hardware-configuration.nix index 3400fae..b264802 100644 --- a/hosts/desktop/hardware-configuration.nix +++ b/hosts/desktop/hardware-configuration.nix @@ -1,17 +1,25 @@ { + config, lib, + pkgs, + modulesPath, ... }: - { - imports = [ ]; + imports = [ + (modulesPath + "/installer/scan/not-detected.nix") + ]; boot.initrd.availableKernelModules = [ + "nvme" + "xhci_pci" + "ahci" + "usb_storage" + "usbhid" "sd_mod" - "sr_mod" ]; boot.initrd.kernelModules = [ ]; - boot.kernelModules = [ ]; + boot.kernelModules = [ "kvm-amd" ]; boot.extraModulePackages = [ ]; fileSystems."/" = { @@ -28,17 +36,8 @@ ]; }; - swapDevices = [ - { device = "/dev/disk/by-label/swap"; } - ]; - - # Enables DHCP on each ethernet and wireless interface. In case of scripted networking - # (the default) this is the recommended approach. When using systemd-networkd it's - # still possible to use this option, but it's recommended to use it in conjunction - # with explicit per-interface declarations with `networking.interfaces..useDHCP`. networking.useDHCP = lib.mkDefault true; - # networking.interfaces.eth0.useDHCP = lib.mkDefault true; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - virtualisation.hypervGuest.enable = true; + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; } diff --git a/system/default.nix b/system/default.nix index d556d7e..59bff06 100644 --- a/system/default.nix +++ b/system/default.nix @@ -18,8 +18,12 @@ # Bootloader. boot.loader.systemd-boot.enable = true; + boot.loader.systemd-boot.configurationLimit = 10; boot.loader.efi.canTouchEfiVariables = true; + # Use latest kernel. + boot.kernelPackages = pkgs.linuxPackages_latest; + # Set your time zone. time.timeZone = "Europe/Berlin";