diff options
| -rw-r--r-- | hosts/desktop/configuration.nix | 1 | ||||
| -rw-r--r-- | hosts/hyper-v/configuration.nix | 3 | ||||
| -rw-r--r-- | hosts/laptop/configuration.nix | 19 | ||||
| -rw-r--r-- | hosts/laptop/hardware-configuration.nix | 30 | ||||
| -rw-r--r-- | modules/common.nix | 4 |
5 files changed, 51 insertions, 6 deletions
diff --git a/hosts/desktop/configuration.nix b/hosts/desktop/configuration.nix index b09a5ee..c1861ba 100644 --- a/hosts/desktop/configuration.nix +++ b/hosts/desktop/configuration.nix @@ -4,6 +4,7 @@ imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix + ../../modules/common.nix ]; networking.hostName = "desktop"; diff --git a/hosts/hyper-v/configuration.nix b/hosts/hyper-v/configuration.nix index f7bc699..8da08c2 100644 --- a/hosts/hyper-v/configuration.nix +++ b/hosts/hyper-v/configuration.nix @@ -9,6 +9,9 @@ networking.hostName = "hyper-v"; + # Use the systemd-boot EFI boot loader. + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; # Hyper-V setup virtualisation.hypervGuest.enable = true; diff --git a/hosts/laptop/configuration.nix b/hosts/laptop/configuration.nix index 9755333..38b01e9 100644 --- a/hosts/laptop/configuration.nix +++ b/hosts/laptop/configuration.nix @@ -4,9 +4,24 @@ imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix + ../../modules/common.nix ]; - networking.hostName = "laptop"; + boot.loader.grub = { + enable = true; + device = "nodev"; + efiSupport = true; + }; + boot.loader.efi.canTouchEfiVariables = false; + boot.loader.efi.efiSysMountPoint = "/boot/efi"; - programs.firefox.enable = true; + networking.hostName = "laptop"; + networking.wireless.iwd.enable = true; + networking.wireless.iwd.settings = { + General.EnableNetworkConfiguration = true; + }; + networking.nameservers = [ + "1.1.1.1" + "8.8.8.8" + ]; } diff --git a/hosts/laptop/hardware-configuration.nix b/hosts/laptop/hardware-configuration.nix new file mode 100644 index 0000000..291f635 --- /dev/null +++ b/hosts/laptop/hardware-configuration.nix @@ -0,0 +1,30 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "rtsx_pci_sdmmc" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-intel" ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/56ae0488-d952-41d8-8128-60a46e979d91"; + fsType = "ext4"; + }; + + fileSystems."/boot/efi" = + { device = "/dev/disk/by-label/ESP"; + fsType = "vfat"; + }; + + swapDevices = [ ]; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +} diff --git a/modules/common.nix b/modules/common.nix index 526767b..2215f93 100644 --- a/modules/common.nix +++ b/modules/common.nix @@ -8,10 +8,6 @@ # Experimental features nix.settings.experimental-features = [ "nix-command" "flakes" ]; - # Use the systemd-boot EFI boot loader. - boot.loader.systemd-boot.enable = true; - boot.loader.efi.canTouchEfiVariables = true; - # Configure network connections interactively with nmcli or nmtui. networking.networkmanager.enable = true; |
