summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorChristian <[email protected]>2026-05-19 21:08:26 -0500
committerChristian <[email protected]>2026-05-19 21:08:26 -0500
commit94f2b8f05515576ea10eeaf0bfadf1cf2742160e (patch)
tree428d7b3ca490511809d120c340dc2c1ce487f72b /modules
parenta2c9e1a485e952ed368f97d2eac6ea70aa88fa61 (diff)
Add KVM module with Windows guest support
Diffstat (limited to 'modules')
-rw-r--r--modules/home/kvm.nix9
-rw-r--r--modules/kvm.nix26
2 files changed, 35 insertions, 0 deletions
diff --git a/modules/home/kvm.nix b/modules/home/kvm.nix
new file mode 100644
index 0000000..4c9438f
--- /dev/null
+++ b/modules/home/kvm.nix
@@ -0,0 +1,9 @@
+{ pkgs, ... }:
+
+{
+ home.packages = with pkgs; [
+ virt-manager
+ virt-viewer
+ virtio-win
+ ];
+}
diff --git a/modules/kvm.nix b/modules/kvm.nix
new file mode 100644
index 0000000..f86c4ad
--- /dev/null
+++ b/modules/kvm.nix
@@ -0,0 +1,26 @@
+{ pkgs, ... }:
+
+{
+ home-manager.users.christian = {
+ imports = [ ./home/kvm.nix ];
+ };
+
+ virtualisation.libvirtd = {
+ enable = true;
+ qemu = {
+ package = pkgs.qemu_kvm;
+ runAsRoot = false;
+ swtpm.enable = true;
+ vhostUserPackages = [ pkgs.virtiofsd ];
+ };
+ };
+
+ virtualisation.spiceUSBRedirection.enable = true;
+
+ users.users.christian.extraGroups = [
+ "libvirtd"
+ "kvm"
+ ];
+
+ programs.dconf.enable = true;
+}