summaryrefslogtreecommitdiff
path: root/modules/hosts/shar/hardware.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/hosts/shar/hardware.nix')
-rw-r--r--modules/hosts/shar/hardware.nix47
1 files changed, 47 insertions, 0 deletions
diff --git a/modules/hosts/shar/hardware.nix b/modules/hosts/shar/hardware.nix
new file mode 100644
index 0000000..7431695
--- /dev/null
+++ b/modules/hosts/shar/hardware.nix
@@ -0,0 +1,47 @@
+{
+ self,
+ inputs,
+ ...
+}: {
+ flake.nixosModules.sharHardware = {
+ config,
+ lib,
+ pkgs,
+ modulesPath,
+ ...
+ }: {
+ imports = [
+ (modulesPath + "/installer/scan/not-detected.nix")
+ ];
+
+ boot.initrd.availableKernelModules = ["ahci" "xhci_pci" "ehci_pci" "nvme" "usbhid" "usb_storage" "sd_mod"];
+ boot.initrd.kernelModules = [];
+ boot.kernelModules = ["kvm-intel"];
+ boot.extraModulePackages = [];
+
+ fileSystems."/" = {
+ device = "/dev/disk/by-uuid/737de4e0-554e-4175-a454-677cf03dbada";
+ fsType = "ext4";
+ };
+
+ fileSystems."/boot" = {
+ device = "/dev/disk/by-uuid/8201-A778";
+ fsType = "vfat";
+ options = ["fmask=0077" "dmask=0077"];
+ };
+
+ swapDevices = [
+ {device = "/dev/disk/by-uuid/429ba137-6ea4-43ba-97ff-e2c2206f935b";}
+ ];
+
+ # 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.<interface>.useDHCP`.
+ networking.useDHCP = lib.mkDefault true;
+ # networking.interfaces.eno1.useDHCP = lib.mkDefault true;
+
+ nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
+ hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
+ };
+}