uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
42
nixos/modules/programs/wireshark.nix
Normal file
42
nixos/modules/programs/wireshark.nix
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.programs.wireshark;
|
||||
wireshark = cfg.package;
|
||||
in {
|
||||
options = {
|
||||
programs.wireshark = {
|
||||
enable = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
Whether to add Wireshark to the global environment and configure a
|
||||
setcap wrapper for 'dumpcap' for users in the 'wireshark' group.
|
||||
'';
|
||||
};
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
default = pkgs.wireshark-cli;
|
||||
defaultText = literalExpression "pkgs.wireshark-cli";
|
||||
description = ''
|
||||
Which Wireshark package to install in the global environment.
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
environment.systemPackages = [ wireshark ];
|
||||
users.groups.wireshark = {};
|
||||
|
||||
security.wrappers.dumpcap = {
|
||||
source = "${wireshark}/bin/dumpcap";
|
||||
capabilities = "cap_net_raw+p";
|
||||
owner = "root";
|
||||
group = "wireshark";
|
||||
permissions = "u+rx,g+x";
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue