autorisation de 'sudo mtr' pour tous les users

This commit is contained in:
2016-08-16 20:05:02 +02:00
parent c2d3bb8cb4
commit 6c45e0bfa2
2 changed files with 18 additions and 0 deletions

View File

@@ -13,6 +13,7 @@ in
./environment.nix
./localisation.nix
#./network-ipv6.nix
./sudo.nix
./service-haveged.nix
./service-monitoring.nix
./service-ssh.nix

17
public/sudo.nix Normal file
View File

@@ -0,0 +1,17 @@
{ config, lib, pkgs, ... }:
let
inherit (lib) mkIf mkMerge mkThenElse;
cfg = config.r6d.config-generator;
computers = config.r6d.computers;
profiles = config.r6d.profiles;
in
mkIf true {
# Authorisation de certaines applications par sudo sans mot de passe
security.sudo.extraConfig = ''
%users ALL = NOPASSWD: ${pkgs.mtr}/bin/mtr
'';
}