diff --git a/modules/nixos/virtualisation/default.nix b/modules/nixos/virtualisation/default.nix index 582c60a..c55781e 100644 --- a/modules/nixos/virtualisation/default.nix +++ b/modules/nixos/virtualisation/default.nix @@ -1,12 +1,21 @@ -_: { - virtualisation = { - docker.enable = true; - incus.enable = true; - libvirtd.enable = true; - lxc = { - enable = true; - lxcfs.enable = true; +{ + config, + libs, + ... +}: { + options = { + virtualisation.enable = lib.mkEnableOption "enable virtualisation"; + }; + config = lib.mkIf config.virtualisation.enable { + virtualisation = { + docker.enable = true; + incus.enable = true; + libvirtd.enable = true; + lxc = { + enable = true; + lxcfs.enable = true; + }; + waydroid.enable = true; }; - waydroid.enable = true; }; }