From e1407ff24ef7f1e78af1b7ad762947ab5f0b0922 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9ana=20=E6=B1=9F?= Date: Sun, 26 Oct 2025 21:21:58 +0800 Subject: [PATCH] nixos/sudo: use doas --- nix/nixosModules/common/sudo-conf.nix | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/nix/nixosModules/common/sudo-conf.nix b/nix/nixosModules/common/sudo-conf.nix index b31388f4..b2b66182 100644 --- a/nix/nixosModules/common/sudo-conf.nix +++ b/nix/nixosModules/common/sudo-conf.nix @@ -1,5 +1,8 @@ -{ - security.sudo.extraConfig = '' - Defaults lecture = always - ''; +{pkgs, ...}: { + security.doas.enable = true; + security.sudo.enable = false; + + environment.systemPackages = [ + pkgs.doas-sudo-shim + ]; }