Unverified Commit 78df37f0 authored by Ryan Horiguchi's avatar Ryan Horiguchi
Browse files

nixos/doas: add package option

parent a6184bac
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -7,8 +7,6 @@
let
  cfg = config.security.doas;

  inherit (pkgs) doas;

  mkUsrString = user: toString user;

  mkGrpString = group: ":${toString group}";
@@ -67,6 +65,8 @@ in
      '';
    };

    package = lib.mkPackageOption pkgs "doas" { };

    wheelNeedsPassword = lib.mkOption {
      type = with lib.types; bool;
      default = true;
@@ -256,11 +256,11 @@ in
      setuid = true;
      owner = "root";
      group = "root";
      source = "${doas}/bin/doas";
      source = lib.getExe cfg.package;
    };

    environment.systemPackages = [
      doas
      cfg.package
    ];

    security.pam.services.doas = {