3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/nixos/modules/programs/iotop.nix

18 lines
325 B
Nix
Raw Normal View History

{ config, pkgs, lib, ... }:
with lib;
let
cfg = config.programs.iotop;
in {
options = {
programs.iotop.enable = mkEnableOption "iotop + setcap wrapper";
};
config = mkIf cfg.enable {
security.wrappers.iotop = {
source = "${pkgs.iotop}/bin/iotop";
capabilities = "cap_net_admin+p";
};
};
}