fix vpn and add rofi toggle

This commit is contained in:
GammaKinematics 2026-03-30 17:57:08 +07:00
parent 43998b73d7
commit ae06e0c8c2
3 changed files with 39 additions and 1 deletions

View file

@ -85,6 +85,18 @@
programs.nix-ld.enable = true;
# Allow lebowski to toggle WireGuard without password
security.polkit.extraConfig = ''
polkit.addRule(function(action, subject) {
if (action.id == "org.freedesktop.systemd1.manage-units" &&
subject.user == "lebowski" &&
(action.lookup("unit") == "wg-quick-wg-services.service" ||
action.lookup("unit") == "wg-quick-wg-vpn.service")) {
return polkit.Result.YES;
}
});
'';
services.pulseaudio.enable = false;
security.rtkit.enable = true;