Commit 684ffbef9da0
Changed files (4)
machine
modules
profiles
machine/honshu.nix
@@ -27,6 +27,7 @@ options edns0
syncthing.enable = true;
virtualization = {
enable = true;
+ nested = true;
listenTCP = true;
};
};
machine/okinawa.nix
@@ -20,6 +20,7 @@ with import ../assets/machines.nix; {
syncthing.enable = true;
virtualization = {
enable = true;
+ nested = true;
listenTCP = true;
};
};
machine/wakasu.nix
@@ -58,6 +58,7 @@ options edns0
};
virtualization = {
enable = true;
+ nested = true;
listenTCP = true;
};
};
modules/profiles/virtualization.nix
@@ -12,6 +12,11 @@ in
description = "Enable virtualization profile";
type = types.bool;
};
+ nested = mkOption {
+ default = false;
+ description = "Enable nested virtualization";
+ type = types.bool;
+ };
listenTCP = mkOption {
default = false;
description = "Make libvirt listen to TCP";
@@ -29,6 +34,11 @@ in
vde2
];
}
+ (mkIf cfg.nested {
+ environment.etc."modprobe.d/kvm.conf".text = ''
+options kvm_intel nested=1
+ '';
+ })
(mkIf config.profiles.desktop.enable {
environment.systemPackages = with pkgs; [ virtmanager ];
})