sisyphus/nixos/modules/virtualisation/virtualbox/default.nix

24 lines
499 B
Nix
Raw Normal View History

2023-10-18 16:47:13 +02:00
{ config, lib, pkgs, ... }:
let
cfg = config.sisyphus.virtualisation.virtualbox;
in {
options.sisyphus.virtualisation.virtualbox.enable = lib.mkEnableOption "VirtualBox";
config = lib.mkIf cfg.enable {
virtualisation.virtualbox = {
host = {
enable = true;
enableExtensionPack = true;
};
guest = {
enable = true;
x11 = true;
};
};
users.extraGroups.vboxusers.members = [
"user-with-access-to-virtualbox"
];
};
}