refactor(Zepyrus): Moved NVIDIA config to hardware-configuration.nix

This commit is contained in:
GaspardCulis 2024-10-08 14:15:07 +02:00
parent 5f02467ae5
commit 028dc4a017
2 changed files with 20 additions and 27 deletions

View file

@ -52,33 +52,6 @@
podman-compose podman-compose
]; ];
# NVIDIA
nixpkgs.config.allowUnfreePredicate = pkg:
builtins.elem (lib.getName pkg) [
# NVIDIA
"nvidia-x11"
"nvidia-settings"
# Steam
"steam"
"steam-original"
"steam-run"
];
hardware.graphics.enable = true;
services.xserver.videoDrivers = ["nvidia"];
hardware.nvidia = {
modesetting.enable = true;
open = false; # Bruuh
prime = {
amdgpuBusId = "PCI:7:0:0";
nvidiaBusId = "PCI:1:0:0";
};
};
#Podman #Podman
virtualisation.containers.enable = true; virtualisation.containers.enable = true;
virtualisation = { virtualisation = {

View file

@ -32,6 +32,26 @@
tmp.useTmpfs = true; tmp.useTmpfs = true;
}; };
#NVIDIA
nixpkgs.config.allowUnfreePredicate = pkg:
builtins.elem (lib.getName pkg) [
"nvidia-x11"
"nvidia-settings"
];
hardware.graphics.enable = true;
hardware.nvidia = {
modesetting.enable = true;
open = false; # Bruuh
prime = {
amdgpuBusId = "PCI:7:0:0";
nvidiaBusId = "PCI:1:0:0";
};
};
services.xserver.videoDrivers = ["nvidia"];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # 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 # (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 # still possible to use this option, but it's recommended to use it in conjunction