update vmgpupassthrought
This commit is contained in:
@@ -24,6 +24,8 @@
|
|||||||
};
|
};
|
||||||
boot.loader.efi.canTouchEfiVariables = false;
|
boot.loader.efi.canTouchEfiVariables = false;
|
||||||
|
|
||||||
|
boot.blacklistedKernelModules = [ "nouveau" ];
|
||||||
|
|
||||||
services.spice-vdagentd.enable = true;
|
services.spice-vdagentd.enable = true;
|
||||||
services.qemuGuest.enable = true;
|
services.qemuGuest.enable = true;
|
||||||
|
|
||||||
@@ -47,16 +49,20 @@
|
|||||||
|
|
||||||
# NVIDIA passthrough guest defaults.
|
# NVIDIA passthrough guest defaults.
|
||||||
# If you pass through an AMD GPU instead, replace with:
|
# If you pass through an AMD GPU instead, replace with:
|
||||||
# services.xserver.videoDrivers = [ "amdgpu" ];
|
|
||||||
services.xserver.videoDrivers = [ "nvidia" ];
|
services.xserver.videoDrivers = [ "nvidia" ];
|
||||||
|
|
||||||
hardware.nvidia = {
|
hardware.nvidia = {
|
||||||
modesetting.enable = true;
|
modesetting.enable = true;
|
||||||
powerManagement.enable = false;
|
#powerManagement.enable = false;
|
||||||
open = false;
|
open = false;
|
||||||
nvidiaSettings = true;
|
#nvidiaSettings = true;
|
||||||
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.xserver.deviceSection = ''
|
||||||
|
Option "AllowEmptyInitialConfiguration"
|
||||||
|
'';
|
||||||
|
|
||||||
powerManagement.cpuFreqGovernor = lib.mkDefault "performance";
|
powerManagement.cpuFreqGovernor = lib.mkDefault "performance";
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
@@ -68,4 +74,12 @@
|
|||||||
|
|
||||||
custom.gaming.enable = true;
|
custom.gaming.enable = true;
|
||||||
custom.gaming.enableXpadneo = false;
|
custom.gaming.enableXpadneo = false;
|
||||||
|
|
||||||
|
services.openssh = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
PasswordAuthentication = true;
|
||||||
|
PermitRootLogin = "no";
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# Do not modify this file directly on every rebuild. It should contain host
|
# Do not modify this file directly on every rebuild. It should contain host
|
||||||
# specific hardware/VM configuration for VMGaming (Proxmox guest).
|
# specific hardware/VM configuration for VMGaming (Proxmox guest).
|
||||||
{ lib, modulesPath, ... }:
|
{ config, lib, modulesPath, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
@@ -10,18 +10,20 @@
|
|||||||
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sr_mod" ];
|
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sr_mod" ];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [ ];
|
boot.kernelModules = [ ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = with config.boot.kernelPackages; [ xone ];
|
||||||
|
boot.kernelParams = [ "console=ttyS0,115200" ];
|
||||||
|
services.getty.autologinUser = null;
|
||||||
|
|
||||||
# Update these labels to match your VM disks if they differ.
|
# Update these labels to match your VM disks if they differ.
|
||||||
fileSystems."/" = {
|
fileSystems."/" = {
|
||||||
device = "/dev/disk/by-label/nixos";
|
device = "/dev/sda2";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
fileSystems."/boot" = {
|
||||||
device = "/dev/disk/by-label/boot";
|
device = "/dev/sda1";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
options = [ "fmask=0077" "dmask=0077" ];
|
# options = [ "fmask=0077" "dmask=0077" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [ ];
|
swapDevices = [ ];
|
||||||
@@ -29,5 +31,7 @@
|
|||||||
networking.useDHCP = lib.mkDefault true;
|
networking.useDHCP = lib.mkDefault true;
|
||||||
services.qemuGuest.enable = true;
|
services.qemuGuest.enable = true;
|
||||||
|
|
||||||
|
hardware.xone.enable = true;
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -56,5 +56,9 @@
|
|||||||
sops
|
sops
|
||||||
age
|
age
|
||||||
];
|
];
|
||||||
|
|
||||||
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCMzLza+1iFSUgZaPzEwpRNW/CvcsbXh8vJ9RevwFntNZdZIVc/j5OLRy+GOojlZdar070PkKDO+Pmtqu1uQ4XE+onqmsxom5JGyYaSScB3l33CLL2jBT7mBqBOVDuTBj3ACLT8fS1eUolI7erShvIH9VUvrg83bZ2CvgA/DjJLHfVCpvx9EsG0Q00k27LNU7yXga8sjK1YikA+o1bKTWavCGOWkZMFXOVeEDR+arOQ440s6f6eg7C+30V02ijRLA6pWFAkj2/fMaD+44IPMVjOj96vvPUJrlL1N7BDPxBlj1rrB35+pUkpVIN4B0etqnkrJIV+IxtmSpkNHr52Y7nkTu3mOWn1P0DcOdR5OA8JZRbSkbL/QW4GzFWs3eN7CMOMwKQdO+1J/wL4U7qrmKEYwcNaprqlDF0SIPp0+l/VWNMe6uK0r5iZwp355PUSR+Zc5skf74wMsZ1LokUlihdI+E6TNGvmDgjqKx6OrI3dyP/eW7xtR7KvbdoaUjy8AE8= alice@nixos"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -45,6 +45,8 @@
|
|||||||
ntfs3g
|
ntfs3g
|
||||||
zip
|
zip
|
||||||
unzip
|
unzip
|
||||||
|
|
||||||
|
scream
|
||||||
];
|
];
|
||||||
|
|
||||||
fonts.packages = with pkgs; [
|
fonts.packages = with pkgs; [
|
||||||
|
|||||||
@@ -20,8 +20,9 @@
|
|||||||
xss-lock
|
xss-lock
|
||||||
dex
|
dex
|
||||||
rofi
|
rofi
|
||||||
i3status
|
# i3status
|
||||||
i3blocks
|
# i3blocks
|
||||||
|
polybar
|
||||||
oh-my-posh
|
oh-my-posh
|
||||||
glances
|
glances
|
||||||
arandr
|
arandr
|
||||||
|
|||||||
Reference in New Issue
Block a user