myNixOSConfig/system/hosts/nixos/hardware-configuration.nix

73 lines
2.4 KiB
Nix
Raw Normal View History

2024-09-07 08:36:34 +02:00
# 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, ... }:
{
boot.supportedFilesystems = [ "btrfs" ];
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/808ce7d4-256c-497e-8f78-83327350846c";
fsType = "btrfs";
options = [ "subvol=root" ];
};
boot.initrd.luks.devices."enc".device = "/dev/disk/by-uuid/926f0f32-87be-4c95-b840-64b4255bd3db";
fileSystems."/home" =
{ device = "/dev/disk/by-uuid/808ce7d4-256c-497e-8f78-83327350846c";
fsType = "btrfs";
options = [ "subvol=home" ];
};
fileSystems."/nix" =
{ device = "/dev/disk/by-uuid/808ce7d4-256c-497e-8f78-83327350846c";
fsType = "btrfs";
options = [ "subvol=nix" ];
};
fileSystems."/persist" =
{ device = "/dev/disk/by-uuid/808ce7d4-256c-497e-8f78-83327350846c";
fsType = "btrfs";
options = [ "subvol=persist" ];
};
fileSystems."/var/log" =
{ device = "/dev/disk/by-uuid/808ce7d4-256c-497e-8f78-83327350846c";
fsType = "btrfs";
# enable noatime and zstd to the other subvolumes aswell
options = [ "subvol=log" "compress=zstd" "noatime" ];
# to have a correct log order
neededForBoot = true;
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/35B5-7D91";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
swapDevices = [ ];
# 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.enp6s0.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp4s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}