mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-01-31 10:58:02 +00:00
hosts/ni: modularize more parts of hardware config
This commit is contained in:
parent
3f291fe665
commit
d8c7033a48
@ -67,26 +67,12 @@
|
|||||||
# The keyfile required for the secrets to be decrypted.
|
# The keyfile required for the secrets to be decrypted.
|
||||||
sops.age.keyFile = "/var/lib/sops-nix/key.txt";
|
sops.age.keyFile = "/var/lib/sops-nix/key.txt";
|
||||||
|
|
||||||
# Get the latest kernel for the desktop experience.
|
|
||||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
|
||||||
|
|
||||||
# Adding a bunch of emulated systems for cross-system building.
|
# Adding a bunch of emulated systems for cross-system building.
|
||||||
boot.binfmt.emulatedSystems = [
|
boot.binfmt.emulatedSystems = [
|
||||||
"aarch64-linux"
|
"aarch64-linux"
|
||||||
"riscv64-linux"
|
"riscv64-linux"
|
||||||
];
|
];
|
||||||
|
|
||||||
# We're using some better filesystems so we're using it.
|
|
||||||
boot.initrd.supportedFilesystems = [ "btrfs" ];
|
|
||||||
boot.supportedFilesystems = [ "btrfs" ];
|
|
||||||
|
|
||||||
services.btrfs.autoScrub = {
|
|
||||||
enable = true;
|
|
||||||
fileSystems = [
|
|
||||||
"/mnt/archives"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# My custom configuration with my custom modules starts here.
|
# My custom configuration with my custom modules starts here.
|
||||||
profiles = {
|
profiles = {
|
||||||
i18n.enable = true;
|
i18n.enable = true;
|
||||||
@ -170,6 +156,5 @@
|
|||||||
longitude = 121.0;
|
longitude = 121.0;
|
||||||
};
|
};
|
||||||
|
|
||||||
services.auto-cpufreq.enable = true;
|
|
||||||
system.stateVersion = "23.11"; # Yes! I read the comment!
|
system.stateVersion = "23.11"; # Yes! I read the comment!
|
||||||
}
|
}
|
||||||
|
@ -6,6 +6,9 @@
|
|||||||
./modules/hardware/traditional-networking.nix
|
./modules/hardware/traditional-networking.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Get the latest kernel for the desktop experience.
|
||||||
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
|
||||||
boot.initrd.availableKernelModules =
|
boot.initrd.availableKernelModules =
|
||||||
[ "xhci_pci" "ahci" "nvme" "usb_storage" "uas" "sd_mod" ];
|
[ "xhci_pci" "ahci" "nvme" "usb_storage" "uas" "sd_mod" ];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ ];
|
||||||
@ -45,6 +48,17 @@
|
|||||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault true;
|
hardware.cpu.intel.updateMicrocode = lib.mkDefault true;
|
||||||
|
|
||||||
|
# We're using some better filesystems so we're using it.
|
||||||
|
boot.initrd.supportedFilesystems = [ "btrfs" ];
|
||||||
|
boot.supportedFilesystems = [ "btrfs" ];
|
||||||
|
|
||||||
|
services.btrfs.autoScrub = {
|
||||||
|
enable = true;
|
||||||
|
fileSystems = [
|
||||||
|
"/mnt/archives"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
# Set up printers.
|
# Set up printers.
|
||||||
services.printing = {
|
services.printing = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@ -56,6 +70,9 @@
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Make your CPU more useful.
|
||||||
|
services.auto-cpufreq.enable = true;
|
||||||
|
|
||||||
# Extend the life of an SSD.
|
# Extend the life of an SSD.
|
||||||
services.fstrim.enable = true;
|
services.fstrim.enable = true;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user