From e5a2f8339ecb3c19fb1d5c8555f7bcef15cd03c4 Mon Sep 17 00:00:00 2001
From: Freya Murphy <freya@freyacat.org>
Date: Mon, 31 Mar 2025 12:42:33 -0400
Subject: [PATCH] vms

---
 nix/system/default.nix | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/nix/system/default.nix b/nix/system/default.nix
index 0ed8ccb..2338fe4 100644
--- a/nix/system/default.nix
+++ b/nix/system/default.nix
@@ -88,7 +88,7 @@
   users.users.${config.user} = {
     isNormalUser = true;
     description = config.fullName;
-    extraGroups = [ "networkmanager" "wheel" "sys" "video" "audio" "docker" ];
+    extraGroups = [ "networkmanager" "wheel" "sys" "video" "audio" "docker" "libvirtd" ];
     home = config.homePath;
     shell = pkgs.zsh;
   };
@@ -138,4 +138,10 @@
       ];
     };
   };
+
+  # vms
+  programs.virt-manager.enable = true;
+  users.groups.libvirtd.members = [config.user];
+  virtualisation.libvirtd.enable = true;
+  virtualisation.spiceUSBRedirection.enable = true;
 }