Allow our user to use libvird

This commit is contained in:
Casper V. Kristensen 2023-10-11 15:16:16 +02:00
parent 9c1c330452
commit fafe664c95

View file

@ -2,9 +2,11 @@
# https://nixos.wiki/wiki/Virt-manager
virtualisation.libvirtd.enable = true;
programs.dconf.enable = true; # virt-manager requires dconf to remember settings
environment.systemPackages = with pkgs; [ virt-manager ];
# Virt-manager requires dconf to remember settings
programs.dconf.enable = true;
# Make virt-manager use QEMU/KVM by default
home-manager.users.caspervk = {
dconf.settings = {
@ -15,6 +17,9 @@
};
};
# Allow our user to use libvird
users.extraGroups.libvirtd.members = [ "caspervk" ];
# Persist libvirt data
environment.persistence."/nix/persist" = {
directories = [