nixos/roles/virtualisation.nix
Ivan Bushchik 4afe642684
Refactor every role to have .enable option
NOTE: any config other than stella will not be working for a while

Signed-off-by: Ivan Bushchik <ivabus@ivabus.dev>
2023-08-22 19:39:11 +03:00

14 lines
345 B
Nix

{ pkgs, config, lib, ... }:
let
cfg = config.my.roles.virtualisation;
in {
options.my.roles.virtualisation.enable = lib.mkEnableOption "Enable tools for virtualisation";
config = lib.mkIf (cfg.enable) {
virtualisation.libvirtd.enable = true;
environment.systemPackages = with pkgs; [
qemu_full
qemu-utils
];
};
}