no password for sudo if admin
This commit is contained in:
@@ -15,6 +15,19 @@
|
|||||||
"wheel"
|
"wheel"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Removes password for sudo
|
||||||
|
security.sudo-rs = lib.mkIf isAdmin {
|
||||||
|
enable = true;
|
||||||
|
extraRules = [{
|
||||||
|
users = [ "john" ];
|
||||||
|
commands = [{
|
||||||
|
command = "ALL";
|
||||||
|
options = [ "NOPASSWD" ];
|
||||||
|
}];
|
||||||
|
}];
|
||||||
|
};
|
||||||
|
|
||||||
# https://github.com/Doc-Steve/dendritic-design-with-flake-parts/wiki/Dendritic_Aspects#multi-context-aspect
|
# https://github.com/Doc-Steve/dendritic-design-with-flake-parts/wiki/Dendritic_Aspects#multi-context-aspect
|
||||||
home-manager.users."${username}" = {
|
home-manager.users."${username}" = {
|
||||||
home.username = "${username}";
|
home.username = "${username}";
|
||||||
|
|||||||
Reference in New Issue
Block a user