2012-03-01 20:10:08 +00:00
|
|
|
{ config, pkgs, ... }:
|
|
|
|
|
|
|
|
with pkgs.lib;
|
|
|
|
|
2012-03-10 14:34:40 +00:00
|
|
|
let virtualbox = config.boot.kernelPackages.virtualbox; in
|
|
|
|
|
2012-03-01 20:10:08 +00:00
|
|
|
{
|
|
|
|
boot.kernelModules = [ "vboxdrv" "vboxnetadp" "vboxnetflt" ];
|
2012-03-10 14:34:40 +00:00
|
|
|
boot.extraModulePackages = [ virtualbox ];
|
|
|
|
environment.systemPackages = [ virtualbox ];
|
2012-03-01 20:10:08 +00:00
|
|
|
|
2012-03-20 16:30:43 +00:00
|
|
|
users.extraGroups = singleton { name = "vboxusers"; };
|
|
|
|
|
|
|
|
services.udev.extraRules =
|
|
|
|
''
|
|
|
|
KERNEL=="vboxdrv", OWNER="root", GROUP="vboxusers", MODE="0660"
|
|
|
|
KERNEL=="vboxnetctl", OWNER="root", GROUP="root", MODE="0600"
|
|
|
|
'';
|
2012-03-01 20:10:08 +00:00
|
|
|
}
|