From 6ced2ac625786c7986ceaa1373cf674baac1b32b Mon Sep 17 00:00:00 2001 From: Julian Mutter Date: Wed, 12 Jun 2024 20:34:49 +0200 Subject: [PATCH] Added hardware config of aspi --- .../aspi/hardware-configuration.nix | 54 +++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 systems/x86_64-linux/aspi/hardware-configuration.nix diff --git a/systems/x86_64-linux/aspi/hardware-configuration.nix b/systems/x86_64-linux/aspi/hardware-configuration.nix new file mode 100644 index 0000000..43f62ab --- /dev/null +++ b/systems/x86_64-linux/aspi/hardware-configuration.nix @@ -0,0 +1,54 @@ +# 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 = [ "vmd" "xhci_pci" "ahci" "nvme" "usb_storage" "usbhid" "sd_mod" ]; + boot.initrd.kernelModules = [ "dm-snapshot" ]; + boot.kernelModules = [ "kvm-intel" ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/bbc45be3-75f5-40c5-8427-2a425de8422c"; + fsType = "btrfs"; + options = [ "subvol=root" "compress=zstd" ]; + }; + + fileSystems."/home" = + { device = "/dev/disk/by-uuid/bbc45be3-75f5-40c5-8427-2a425de8422c"; + fsType = "btrfs"; + options = [ "subvol=home" "compress=zstd" ]; + }; + + fileSystems."/nix" = + { device = "/dev/disk/by-uuid/bbc45be3-75f5-40c5-8427-2a425de8422c"; + fsType = "btrfs"; + options = [ "subvol=nix" "compress=zstd" "noatime" ]; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/7040-F37C"; + fsType = "vfat"; + }; + + swapDevices = + [ { device = "/dev/disk/by-uuid/26140b4a-0579-406d-a484-35aa31b32e80"; } + ]; + + # 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.enp1s0.useDHCP = lib.mkDefault true; + # networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + powerManagement.cpuFreqGovernor = lib.mkDefault "powersave"; + hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +}