git.iko.soy/typeable/nixpkgs
on master help sign in
nixos/virtualbox: Fix warning on enableHardening.

The warning was displayed whenever services.virtualboxHost.enable was true, but if people were to enable hardening, they'd still get that annoying message. Signed-off-by: aszlig <aszlig@redmoonstudios.org>

commite36bec661c2dae4c306867fa58faea833806af52 authoraszlig <aszlig@redmoonstudios.org> dateTue 16 Dec 2014, 09:54 (12 years ago) parent477bc03
1 file changed+2−2
nixos/modules/programs/virtualbox-host.nix+2−2
nixos/modules/programs/virtualbox-host.nix+2−2
@@ -54,12 +54,12 @@ in
5454 boot.extraModulePackages = [ virtualbox ];
5555 environment.systemPackages = [ virtualbox ];
5656
57− warnings = singleton (
57+ warnings = mkIf (!cfg.enableHardening) (singleton (
5858 "Hardening is currently disabled for VirtualBox, because of some " +
5959 "issues in conjunction with host-only-interfaces. If you don't use " +
6060 "hostonlyifs, it's strongly recommended to set " +
6161 "`services.virtualboxHost.enableHardening = true'!"
62− );
62+ ));
6363
6464 security.setuidOwners = let
6565 mkVboxStub = program: {