GPU Passthrough for plex
This commit is contained in:
parent
50d2054bf2
commit
8cefe48157
@ -3,9 +3,8 @@
|
|||||||
imports = [ ./shared.nix ];
|
imports = [ ./shared.nix ];
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
boot.loader.grub.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
boot.loader.grub.device = "/dev/sda";
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
boot.loader.grub.useOSProber = true;
|
|
||||||
|
|
||||||
system.stateVersion = "24.05";
|
system.stateVersion = "24.05";
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,16 @@
|
|||||||
./headless.nix
|
./headless.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
services.xserver.videoDrivers = ["nvidia"];
|
||||||
|
hardware.opengl.enable = true;
|
||||||
|
hardware.nvidia = {
|
||||||
|
open = false;
|
||||||
|
modesetting.enable = true;
|
||||||
|
powerManagement.enable = false;
|
||||||
|
powerManagement.finegrained = false;
|
||||||
|
nvidiaSettings = true;
|
||||||
|
};
|
||||||
|
|
||||||
users.users.media = import ./user.nix;
|
users.users.media = import ./user.nix;
|
||||||
networking.hostName = "r330-media";
|
networking.hostName = "r330-media";
|
||||||
|
|
||||||
@ -12,7 +22,7 @@
|
|||||||
networking.defaultGateway = "192.168.100.1";
|
networking.defaultGateway = "192.168.100.1";
|
||||||
networking.nameservers = [ "192.168.100.1" ];
|
networking.nameservers = [ "192.168.100.1" ];
|
||||||
networking.firewall.allowedTCPPorts = [ 80 443 32400 ];
|
networking.firewall.allowedTCPPorts = [ 80 443 32400 ];
|
||||||
networking.interfaces.ens18.ipv4.addresses = [
|
networking.interfaces.enp6s18.ipv4.addresses = [
|
||||||
{
|
{
|
||||||
address = "192.168.100.5";
|
address = "192.168.100.5";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
|
@ -8,20 +8,26 @@
|
|||||||
[ (modulesPath + "/profiles/qemu-guest.nix")
|
[ (modulesPath + "/profiles/qemu-guest.nix")
|
||||||
];
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
|
boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ahci" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [ ];
|
boot.kernelModules = [ ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
fileSystems."/" = {
|
fileSystems."/" =
|
||||||
device = "/dev/disk/by-uuid/3f87972b-cf61-4efd-883c-b9f794775232";
|
{ device = "/dev/disk/by-uuid/d761e265-99eb-4dd6-a92d-40ba56f962ec";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/storage" = {
|
fileSystems."/mnt/storage" =
|
||||||
device = "/dev/disk/by-uuid/b579c911-e74c-4f03-b918-a4e5a6b764ab";
|
{ device = "/dev/disk/by-uuid/b579c911-e74c-4f03-b918-a4e5a6b764ab";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" =
|
||||||
|
{ device = "/dev/disk/by-uuid/3B58-9662";
|
||||||
|
fsType = "vfat";
|
||||||
|
options = [ "fmask=0022" "dmask=0022" ];
|
||||||
|
};
|
||||||
|
|
||||||
swapDevices = [ ];
|
swapDevices = [ ];
|
||||||
|
|
||||||
@ -30,7 +36,7 @@
|
|||||||
# 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
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||||
networking.useDHCP = lib.mkDefault true;
|
networking.useDHCP = lib.mkDefault true;
|
||||||
# networking.interfaces.ens18.useDHCP = lib.mkDefault true;
|
# networking.interfaces.enp6s18.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
@ -24,9 +24,11 @@ in {
|
|||||||
btop
|
btop
|
||||||
p7zip
|
p7zip
|
||||||
ripgrep
|
ripgrep
|
||||||
|
openvpn
|
||||||
|
pciutils
|
||||||
fastfetch
|
fastfetch
|
||||||
bitwarden-cli
|
bitwarden-cli
|
||||||
openvpn
|
nvtopPackages.full
|
||||||
|
|
||||||
# Dev tools
|
# Dev tools
|
||||||
clang
|
clang
|
||||||
|
Loading…
x
Reference in New Issue
Block a user