From b2eb6df5f5a75d2658fc99e35e6dfeaf71ac3c62 Mon Sep 17 00:00:00 2001 From: Sergei Bulavintsev Date: Mon, 26 Feb 2024 11:36:57 +0300 Subject: [PATCH] feat(nix): add virt manager darwin module --- .../virtualisation/virt-manager/default.nix | 21 +++++++++++++++++++ nix/systems/aarch64-darwin/mbp13/default.nix | 4 ++++ 2 files changed, 25 insertions(+) create mode 100644 nix/modules/darwin/virtualisation/virt-manager/default.nix diff --git a/nix/modules/darwin/virtualisation/virt-manager/default.nix b/nix/modules/darwin/virtualisation/virt-manager/default.nix new file mode 100644 index 0000000..449f719 --- /dev/null +++ b/nix/modules/darwin/virtualisation/virt-manager/default.nix @@ -0,0 +1,21 @@ +{ + options, + config, + lib, + pkgs, + ... +}: +with lib; +with lib.custom; let + cfg = config.custom.virtualisation.virt-manager; +in { + options.custom.virtualisation.virt-manager = with types; { + enable = mkBoolOpt false "Whether or not to enable virt-manager."; + }; + + config = mkIf cfg.enable { + environment.systemPackages = with pkgs; [ + virt-manager + ]; + }; +} diff --git a/nix/systems/aarch64-darwin/mbp13/default.nix b/nix/systems/aarch64-darwin/mbp13/default.nix index 2c3819e..f76bea0 100644 --- a/nix/systems/aarch64-darwin/mbp13/default.nix +++ b/nix/systems/aarch64-darwin/mbp13/default.nix @@ -10,6 +10,10 @@ with lib.custom; { develop = enabled; }; + virtualisation = { + virt-manager = enabled; + }; + desktop.yabai = enabled; desktop.addons.wezterm = enabled; };