diff --git a/nixos/modules/services/networking/globalprotect-vpn.nix b/nixos/modules/services/networking/globalprotect-vpn.nix index 4292bba78f76..87ce8a5e142f 100644 --- a/nixos/modules/services/networking/globalprotect-vpn.nix +++ b/nixos/modules/services/networking/globalprotect-vpn.nix @@ -1,7 +1,4 @@ { config, lib, pkgs, ... }: - -with lib; - let cfg = config.services.globalprotect; @@ -14,9 +11,9 @@ in { options.services.globalprotect = { - enable = mkEnableOption "globalprotect"; + enable = lib.mkEnableOption "globalprotect"; - settings = mkOption { + settings = lib.mkOption { description = '' GlobalProtect-openconnect configuration. For more information, visit . @@ -27,21 +24,21 @@ in openconnect-args = "--script=/path/to/vpnc-script"; }; }; - type = types.attrs; + type = lib.types.attrs; }; - csdWrapper = mkOption { + csdWrapper = lib.mkOption { description = '' A script that will produce a Host Integrity Protection (HIP) report, as described at ''; default = null; - example = literalExpression ''"''${pkgs.openconnect}/libexec/openconnect/hipreport.sh"''; - type = types.nullOr types.path; + example = lib.literalExpression ''"''${pkgs.openconnect}/libexec/openconnect/hipreport.sh"''; + type = lib.types.nullOr lib.types.path; }; }; - config = mkIf cfg.enable { + config = lib.mkIf cfg.enable { services.dbus.packages = [ pkgs.globalprotect-openconnect ]; environment.etc."gpservice/gp.conf".text = lib.generators.toINI { } cfg.settings;