mirror of
https://github.com/oddlama/nix-config.git
synced 2025-10-11 07:10:39 +02:00
refactor: move nvidia settings to hardware/nvidia
This commit is contained in:
parent
ae62336669
commit
0eb6ac95e4
5 changed files with 13 additions and 18 deletions
|
@ -16,12 +16,12 @@ This is my personal nix config. It's still in the making, but this is what I got
|
||||||
| | Name | Type | Purpose
|
| | Name | Type | Purpose
|
||||||
---|---|---|---
|
---|---|---|---
|
||||||
💻 | nom | Gigabyte AERO 15-W8 (i7-8750H) | My laptop and my main portable development machine <sub>Framework when?</sub>
|
💻 | nom | Gigabyte AERO 15-W8 (i7-8750H) | My laptop and my main portable development machine <sub>Framework when?</sub>
|
||||||
|
🖥️ | potksed | PC (AMD Ryzen 9 5900X) | Main workstation and development machine
|
||||||
🖥️ | ward | ODROID H3 | Energy efficient SBC for my home firewall and some lightweight services using microvms.
|
🖥️ | ward | ODROID H3 | Energy efficient SBC for my home firewall and some lightweight services using microvms.
|
||||||
🥔 | zackbiene | ODROID N2+ | ARM SBC for home automation, isolating the sketchy stuff from my main network
|
🥔 | zackbiene | ODROID N2+ | ARM SBC for home automation, isolating the sketchy stuff from my main network
|
||||||
☁️ | envoy | Hetzner Cloud server | Mailserver
|
☁️ | envoy | Hetzner Cloud server | Mailserver
|
||||||
☁️ | sentinel | Hetzner Cloud server | Proxies and protects my local services
|
☁️ | sentinel | Hetzner Cloud server | Proxies and protects my local services
|
||||||
|
|
||||||
<!-- 🖥️ workstation -->
|
|
||||||
<!-- 🖥️ home server -->
|
<!-- 🖥️ home server -->
|
||||||
|
|
||||||
<sub>
|
<sub>
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
inputs.nixos-hardware.nixosModules.common-pc-ssd
|
inputs.nixos-hardware.nixosModules.common-pc-ssd
|
||||||
|
|
||||||
../../modules/optional/hardware/physical.nix
|
../../modules/optional/hardware/physical.nix
|
||||||
|
../../modules/optional/hardware/nvidia.nix
|
||||||
|
|
||||||
../../modules
|
../../modules
|
||||||
../../modules/optional/boot-efi.nix
|
../../modules/optional/boot-efi.nix
|
||||||
|
@ -30,21 +31,7 @@
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod"];
|
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod"];
|
||||||
|
|
||||||
hardware.nvidia.modesetting.enable = true;
|
# TODO goodbye once -sk keys.
|
||||||
hardware.opengl = {
|
|
||||||
enable = true;
|
|
||||||
driSupport = true;
|
|
||||||
driSupport32Bit = true;
|
|
||||||
};
|
|
||||||
hardware.nvidia.powerManagement.enable = true;
|
|
||||||
hardware.nvidia.open = false;
|
|
||||||
hardware.nvidia.nvidiaSettings = true;
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
killall
|
|
||||||
vaapiVdpau
|
|
||||||
libvdpau-va-gl
|
|
||||||
];
|
|
||||||
environment.shellInit = ''
|
environment.shellInit = ''
|
||||||
gpg-connect-agent /bye
|
gpg-connect-agent /bye
|
||||||
export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
|
export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
|
||||||
|
|
|
@ -3,4 +3,9 @@
|
||||||
./fonts.nix
|
./fonts.nix
|
||||||
./wayland.nix
|
./wayland.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
vaapiVdpau
|
||||||
|
libvdpau-va-gl
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,12 +5,14 @@
|
||||||
nvidia = {
|
nvidia = {
|
||||||
modesetting.enable = true;
|
modesetting.enable = true;
|
||||||
nvidiaPersistenced = true;
|
nvidiaPersistenced = true;
|
||||||
|
nvidiaSettings = true;
|
||||||
|
open = false;
|
||||||
|
powerManagement.enable = true;
|
||||||
};
|
};
|
||||||
opengl = {
|
opengl = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
driSupport = true;
|
||||||
driSupport32Bit = true;
|
driSupport32Bit = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services.xserver.videoDrivers = ["nvidia"];
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
fd
|
fd
|
||||||
file
|
file
|
||||||
hexyl
|
hexyl
|
||||||
|
killall
|
||||||
ncdu
|
ncdu
|
||||||
neofetch
|
neofetch
|
||||||
rage
|
rage
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue