diff options
author | Azat Bahawi <azat@bahawi.net> | 2024-03-31 21:29:27 +0300 |
---|---|---|
committer | Azat Bahawi <azat@bahawi.net> | 2024-03-31 21:29:27 +0300 |
commit | 9a5427e3a0c0ccf2a82dc503149a26b23fbd6004 (patch) | |
tree | f28beec29deeea36038615a8fb98a810891940b5 /modules/nixos/libvirtd.nix | |
parent | 2024-03-19 (diff) |
2024-03-31
Diffstat (limited to 'modules/nixos/libvirtd.nix')
-rw-r--r-- | modules/nixos/libvirtd.nix | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/modules/nixos/libvirtd.nix b/modules/nixos/libvirtd.nix index 0d58f5e..009fd24 100644 --- a/modules/nixos/libvirtd.nix +++ b/modules/nixos/libvirtd.nix @@ -4,13 +4,15 @@ pkgs, ... }: -with lib; let +with lib; +let cfg = config.nixfiles.modules.libvirtd; -in { +in +{ options.nixfiles.modules.libvirtd.enable = mkEnableOption "libvirtd"; config = mkIf cfg.enable { - ark.directories = ["/var/lib/libvirt"]; + ark.directories = [ "/var/lib/libvirt" ]; hm.home.packages = with pkgs; [ bridge-utils @@ -36,7 +38,7 @@ in { ovmf = { enable = true; - packages = [pkgs.OVMFFull.fd]; + packages = [ pkgs.OVMFFull.fd ]; }; swtpm = { @@ -46,6 +48,6 @@ in { }; }; - my.extraGroups = ["libvirtd"]; + my.extraGroups = [ "libvirtd" ]; }; } |