35 lines
944 B
Nix
35 lines
944 B
Nix
|
{ config, lib, pkgs, ... }:
|
||
|
{
|
||
|
# GPU
|
||
|
/*
|
||
|
hardware.opengl = {
|
||
|
enable = true;
|
||
|
driSupport = true;
|
||
|
driSupport32Bit = true;
|
||
|
};
|
||
|
*/
|
||
|
services.xserver.videoDrivers = ["nvidia"];
|
||
|
#pkgs.autoAddDriverRunpath
|
||
|
hardware.nvidia = {
|
||
|
modesetting.enable = true;
|
||
|
# Enable power management (do not disable this unless you have a reason to).
|
||
|
# Likely to cause problems on laptops and with screen tearing if disabled.
|
||
|
powerManagement.enable = true;
|
||
|
# Do not disable this unless your GPU is unsupported or if you have a good reason to.
|
||
|
open = true;
|
||
|
# Enable the Nvidia settings menu,
|
||
|
# accessible via `nvidia-settings`.
|
||
|
nvidiaSettings = true;
|
||
|
|
||
|
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||
|
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||
|
};
|
||
|
|
||
|
environment.systemPackages = with pkgs; [
|
||
|
#nvtop-nvidia
|
||
|
nvtopPackages.nvidia
|
||
|
];
|
||
|
|
||
|
|
||
|
}
|