blob: bf2ef38e909043124720d3cf7573cbb40de5a81c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
{ pkgs, ... }:
{
security.sudo.enable = false;
security.doas = {
enable = true;
wheelNeedsPassword = false;
extraRules = [{
groups = [ "wheel" ];
noPass = true;
# keepEnv = true;
# I need to set NIX_PATH explicitly, since my user and root use different paths
setEnv = [ "NIX_PATH=nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixos:nixos-config=/etc/nixos/configuration.nix:/nix/var/nix/profiles/per-user/root/channels" ];
}];
};
environment.shellAliases = {
sudo = "doas";
};
}
|