109 lines
		
	
	
	
		
			3.5 KiB
		
	
	
	
		
			Nix
		
	
	
	
	
	
			
		
		
	
	
			109 lines
		
	
	
	
		
			3.5 KiB
		
	
	
	
		
			Nix
		
	
	
	
	
	
{ config, lib, pkgs, modulesPath, ... }:
 | 
						|
 | 
						|
{
 | 
						|
  imports =
 | 
						|
    [ (modulesPath + "/installer/scan/not-detected.nix")
 | 
						|
    ];
 | 
						|
 | 
						|
  boot.initrd.availableKernelModules = [ "vmd" "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
 | 
						|
  boot.initrd.kernelModules = [ ];
 | 
						|
  boot.kernelModules = [ "kvm-intel" "vfio-pci" ];
 | 
						|
  boot.extraModulePackages = lib.attrVals [ "rtl8812au" ] config.boot.kernelPackages;
 | 
						|
 | 
						|
 | 
						|
  boot.kernelParams = [
 | 
						|
    "loglevel=3"
 | 
						|
    "iommu=pt"
 | 
						|
    "intel_iommu=on"
 | 
						|
  ];
 | 
						|
 | 
						|
  fileSystems = {
 | 
						|
    "/" =
 | 
						|
      { device = "/dev/disk/by-uuid/8e30bb30-eacf-4d7d-bcec-c2b39982de13";
 | 
						|
        fsType = "btrfs";
 | 
						|
        options = [ "subvol=nix" "compress=zstd" ];
 | 
						|
      };
 | 
						|
    "/home" = {
 | 
						|
      device = "/dev/disk/by-uuid/8e30bb30-eacf-4d7d-bcec-c2b39982de13";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=homes/stitchymain" "compress=zstd" ];
 | 
						|
    };
 | 
						|
    "/nix/store" = {
 | 
						|
      device = "/dev/disk/by-uuid/8e30bb30-eacf-4d7d-bcec-c2b39982de13";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=store" "noatime" "compress=zstd" ];
 | 
						|
    };
 | 
						|
    "/persist" = {
 | 
						|
      device = "/dev/disk/by-uuid/8e30bb30-eacf-4d7d-bcec-c2b39982de13";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=@persist" ];
 | 
						|
    };
 | 
						|
    "/boot" = {
 | 
						|
      device = "/dev/disk/by-uuid/CB12-5062";
 | 
						|
      fsType = "vfat";
 | 
						|
    };
 | 
						|
    "/home/stitchynyan/Music" = {
 | 
						|
      device = "/dev/disk/by-uuid/feb8239f-5d09-4184-8e46-52185beaa040";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=music/stitchtunes" "compress=zstd" "x-systemd.automount" ];
 | 
						|
    };
 | 
						|
    "/home/stitchynyan/Pictures" = {
 | 
						|
      device = "/dev/disk/by-uuid/feb8239f-5d09-4184-8e46-52185beaa040";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=pictures/stitchpics" "compress=zstd" "x-systemd.automount" ];
 | 
						|
    };
 | 
						|
    "/home/stitchynyan/Programs/Steam" = {
 | 
						|
      device = "/dev/disk/by-uuid/feb8239f-5d09-4184-8e46-52185beaa040";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=games/stitchgames" "compress=zstd" "x-systemd.automount" ];
 | 
						|
    };
 | 
						|
    "/home/stitchynyan/Videos" = {
 | 
						|
      device = "/dev/disk/by-uuid/feb8239f-5d09-4184-8e46-52185beaa040";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=videos/stitchshows" "compress=zstd" "x-systemd.automount" ];
 | 
						|
    };
 | 
						|
    "/home/stitchynyan/VirtualMachines" = {
 | 
						|
      device = "/dev/disk/by-uuid/feb8239f-5d09-4184-8e46-52185beaa040";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=virtualmachines/stitchvms" "x-systemd.automount" ];
 | 
						|
    };
 | 
						|
    "/persist/libvirtd/ssd-images" = {
 | 
						|
      device = "/dev/disk/by-uuid/2acfecd4-0a2c-4eb0-b402-3899a654925e";
 | 
						|
      fsType = "btrfs";
 | 
						|
      options = [ "subvol=@virtualmachines" "noatime" ];
 | 
						|
    };
 | 
						|
  };
 | 
						|
 | 
						|
  boot.initrd.luks.devices."luksdev".device = "/dev/disk/by-uuid/775b3331-6045-474a-8b9e-523f31a1a8a2";
 | 
						|
 | 
						|
  environment.etc."crypttab".text = ''
 | 
						|
    data /dev/disk/by-uuid/15510fe2-5b98-4148-8710-deb8f5bd68e6 /persist/secrets/drive.key
 | 
						|
    ssd /dev/disk/by-uuid/ce3b62f3-079a-4dc4-bd1d-2494668a96c2 /persist/secrets/ssd.key
 | 
						|
  '';
 | 
						|
 | 
						|
  swapDevices = [ ];
 | 
						|
 | 
						|
  services.xserver.displayManager.lightdm.enable = false;
 | 
						|
  services.monado = {
 | 
						|
    enable = true;
 | 
						|
    defaultRuntime = true;
 | 
						|
  };
 | 
						|
 | 
						|
  systemd.user.services.monado.environment = {
 | 
						|
    STEAMVR_LH_ENABLE = "1";
 | 
						|
    XRT_COMPOSITOR_COMPUTE = "1";
 | 
						|
  };
 | 
						|
 | 
						|
  hardware = {
 | 
						|
    graphics = {
 | 
						|
      enable = true;
 | 
						|
      enable32Bit = true;
 | 
						|
    };
 | 
						|
  };
 | 
						|
 | 
						|
  networking.useDHCP = lib.mkDefault true;
 | 
						|
 | 
						|
  nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
 | 
						|
  powerManagement.cpuFreqGovernor = lib.mkDefault "schedutil";
 | 
						|
  hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
 | 
						|
}
 |