changes to fix compliance with home server

This commit is contained in:
2025-07-01 20:21:38 +02:00
parent 6d96d1a015
commit 7dfec3a2b0
23 changed files with 232 additions and 307 deletions

View File

@@ -35,10 +35,12 @@ in {
./modules.nix
];
boot.initrd.luks.devices."luks-47b35d4b-467a-4637-a5f9-45177da62897".device = "/dev/disk/by-uuid/47b35d4b-467a-4637-a5f9-45177da62897";
networking.hostName = "cnixlab";
environment.variables.NH_FLAKE = "/home/cnstlab/.nix-config";
# # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
system.stateVersion = lib.mkDefault "23.11";
system.stateVersion = lib.mkDefault "25.05";
}

View File

@@ -12,59 +12,36 @@
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod"];
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod"];
boot.initrd.kernelModules = [];
boot.kernelModules = ["kvm-amd"];
boot.kernelModules = [];
boot.extraModulePackages = [];
fileSystems."/" = {
device = "/dev/disk/by-uuid/90eafb57-0f89-4c2a-b417-4e0f2fba5f47";
fsType = "btrfs";
options = ["subvol=root"];
device = "/dev/disk/by-uuid/a0a3595f-e61c-475c-8f4e-bfbb05582c20";
fsType = "ext4";
};
boot.initrd.luks.devices."enc".device = "/dev/disk/by-uuid/36144799-13f2-4166-9bfe-b29c3df435ab";
fileSystems."/home" = {
device = "/dev/disk/by-uuid/90eafb57-0f89-4c2a-b417-4e0f2fba5f47";
fsType = "btrfs";
options = ["subvol=home"];
};
fileSystems."/nix" = {
device = "/dev/disk/by-uuid/90eafb57-0f89-4c2a-b417-4e0f2fba5f47";
fsType = "btrfs";
options = ["subvol=nix"];
};
fileSystems."/persist" = {
device = "/dev/disk/by-uuid/90eafb57-0f89-4c2a-b417-4e0f2fba5f47";
fsType = "btrfs";
options = ["subvol=persist"];
};
fileSystems."/var/log" = {
device = "/dev/disk/by-uuid/90eafb57-0f89-4c2a-b417-4e0f2fba5f47";
fsType = "btrfs";
options = ["subvol=log"];
neededForBoot = true;
};
boot.initrd.luks.devices."luks-4f289fde-55ed-4b05-a6ee-d396db2a887b".device = "/dev/disk/by-uuid/4f289fde-55ed-4b05-a6ee-d396db2a887b";
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/1D4A-3121";
device = "/dev/disk/by-uuid/E03E-5458";
fsType = "vfat";
options = ["fmask=0022" "dmask=0022"];
options = ["fmask=0077" "dmask=0077"];
};
swapDevices = [{device = "/dev/disk/by-uuid/91e16a5f-6a1c-4c7d-aa61-5823068fdaf0";}];
swapDevices = [
{device = "/dev/disk/by-uuid/704e09db-c7dd-462b-9560-47bbf845905d";}
];
# 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;
# networking.interfaces.wlp11s0.useDHCP = lib.mkDefault true;
# networking.interfaces.enp5s0.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;

View File

@@ -4,8 +4,7 @@
kernel = {
extraBlacklistedModules = [];
extraKernelParams = [];
hardware = "amd";
variant = "latest";
variant = "stable";
};
loader = {
default = {
@@ -18,7 +17,7 @@
};
hardware = {
bluetooth = {
enable = true;
enable = false;
};
graphics = {
amd = {

View File

@@ -21,13 +21,8 @@
enable = true;
};
graphics = {
amd = {
enable = true;
packageSet = "standard";
};
nvidia = {
enable = false;
};
enable = true;
vendor = "amd";
};
logitech = {
enable = false;

View File

@@ -39,7 +39,10 @@ in {
networking.hostName = "cnixtop";
environment.variables.NH_FLAKE = "/home/cnst/.nix-config";
environment.variables = {
NH_FLAKE = "/home/cnst/.nix-config";
GEMINI_API_KEY = config.age.secrets.gcapi.path;
};
programs.hyprland.settings = {
monitor = [

View File

@@ -12,19 +12,6 @@
(modulesPath + "/installer/scan/not-detected.nix")
];
# Use system-wide overlays to override linux-firmware
# nixpkgs.overlays = [
# (final: prev: {
# linux-firmware = prev.linux-firmware.overrideAttrs (old: rec {
# version = "20250509";
# src = prev.fetchzip {
# url = "https://cdn.kernel.org/pub/linux/kernel/firmware/linux-firmware-${version}.tar.xz";
# hash = "sha256-0FrhgJQyCeRCa3s0vu8UOoN0ZgVCahTQsSH0o6G6hhY=";
# };
# });
# })
# ];
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod"];
boot.initrd.kernelModules = [];
boot.kernelModules = ["kvm-amd"];

View File

@@ -21,13 +21,8 @@
enable = true;
};
graphics = {
amd = {
enable = true;
packageSet = "standard";
};
nvidia = {
enable = false;
};
enable = true;
vendor = "amd";
};
logitech = {
enable = true;

View File

@@ -21,11 +21,9 @@
enable = false;
};
graphics = {
amd = {
enable = false;
};
enable = true;
vendor = "nvidia";
nvidia = {
enable = true;
package = "beta";
open = {
enable = true;