virt-manager: init

This commit is contained in:
Kevin Baensch 2024-12-07 22:53:20 +01:00
parent 02182f5134
commit 1f5952fffa
Signed by: derped
GPG key ID: C0F1D326C7626543
2 changed files with 18 additions and 0 deletions

View file

@ -46,6 +46,7 @@ let
"cups" "cups"
"lp" "lp"
]) ])
++ (optional config.programs.virt-manager.enable "libvirtd")
++ (optional (withDocker && !withPodman) "docker") ++ (optional (withDocker && !withPodman) "docker")
++ (optional withPodman "podman"); ++ (optional withPodman "podman");
shell = "${pkgs.zsh}/bin/zsh"; shell = "${pkgs.zsh}/bin/zsh";

17
services/virt-manager.nix Normal file
View file

@ -0,0 +1,17 @@
{
config,
lib,
...
}:
with lib;
mkIf (elem "virt-manager" config.machine.services) {
virtualisation.libvirtd.enable = true;
programs.virt-manager.enable = true;
dconf.settings = {
"org/virt-manager/virt-manager/connections" = {
autoconnect = [ "qemu:///system" ];
uris = [ "qemu:///system" ];
};
};
}