git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #5300 from ambrop72/virtualbox-network-interface

virtualbox: Allow disabling the network interface.

commite1383d0833d5d4f910362d3d16e4371612f9bd29 authorJaka Hudoklin <jakahudoklin@gmail.com> dateThu 11 Dec 2014, 23:51 (12 years ago) parent786a0c99fa2c35
1 file changed+6−1
nixos/modules/programs/virtualbox-host.nix+6−1
nixos/modules/programs/virtualbox-host.nix+6−1
@@ -9,6 +9,11 @@ in
99{
1010 options = {
1111 services.virtualboxHost.enable = mkEnableOption "VirtualBox Host support";
12+ services.virtualboxHost.addNetworkInterface = mkOption {
13+ type = types.bool;
14+ default = true;
15+ description = "Automatically set up a vboxnet0 host-only network interface.";
16+ };
1217 };
1318
1419 config = mkIf config.services.virtualboxHost.enable {
@@ -46,7 +51,7 @@ in
4651 '';
4752
4853 # Since we lack the right setuid binaries, set up a host-only network by default.
49−
54+ } // mkIf config.services.virtualboxHost.addNetworkInterface {
5055 systemd.services."vboxnet0" =
5156 { description = "VirtualBox vboxnet0 Interface";
5257 requires = [ "dev-vboxnetctl.device" ];