virtualization plus wifif

This commit is contained in:
stitchy 2024-06-05 05:46:08 -07:00
parent b27b33d13e
commit fa48674845
Signed by: stitchy
SSH key fingerprint: SHA256:p+xeQgmOvQ2br1d2STl5OnRRMef2LRqCtGA7SO4WYk0
2 changed files with 9 additions and 7 deletions

View file

@ -1,15 +1,13 @@
{ config, pkgs, lib, ... }:
let
passthrough = pkgs.writeShellApplication {
name = "pasthrough.sh";
name = "passthrough.sh";
runtimeInputs = lib.attrVals [ "coreutils" "kmod" "libvirt" "procps" ] pkgs;
text = ''
GUEST_NAME="$1"
HOOK_NAME="$2"
STATE_NAME="$3"
echo 19>/home/stitchynyan/startlogfile
BASH_XTRACEFD=19
set -x
# For the windows 10 VM
@ -19,7 +17,7 @@ let
if [[ "$HOOK_NAME/$STATE_NAME" == "prepare/begin" ]]; then
# Remove Hyprland
pkill Hyprland
#pkill Hyprland
# Unbind VTconsoles
echo 0 > /sys/class/vtconsole/vtcon0/bind
@ -77,15 +75,19 @@ in {
../default.nix
];
virtualisation.libvirtd.hooks.qemu = {
passthrough = "${passthrough}";
passthrough = "${passthrough}/bin/passthrough.sh";
};
stitchyconf = {
artPkgs.enable = true;
};
virtualisation.libvirtd.enable = true;
virtualisation.libvirtd = {
enable = true;
onBoot = "ignore";
};
hardware = {
opentabletdriver.enable = true;
steam-hardware.enable = true;
};

View file

@ -8,7 +8,7 @@
boot.initrd.availableKernelModules = [ "vmd" "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" "vfio-pci" ];
boot.extraModulePackages = [ ];
boot.extraModulePackages = lib.attrVals [ "rtl8812au" ] config.boot.kernelPackages;
boot.kernelParams = [
"loglevel=3"