System: Add networkmanager modify system polkit permission
This commit is contained in:
@ -66,7 +66,7 @@ in {
|
||||
mkIf (!cfg.useNetworkManager) {text = names;};
|
||||
|
||||
# Allow to enable/disable tunnels without root password
|
||||
modules.polkit.allowed-system-services = let
|
||||
modules.polkit.allowedSystemServices = let
|
||||
vpn-services = lib.pipe cfg.wireguard-tunnels [
|
||||
attrNames
|
||||
(map (v: "${v}.service"))
|
||||
@ -74,6 +74,11 @@ in {
|
||||
in
|
||||
mkIf (!cfg.useNetworkManager) vpn-services;
|
||||
|
||||
modules.polkit.allowedActions = mkIf cfg.useNetworkManager [
|
||||
# NOTE: List permissions by running "nmcli general permissions"
|
||||
"org.freedesktop.NetworkManager.settings.modify.system"
|
||||
];
|
||||
|
||||
# General Networking Settings
|
||||
networking = {
|
||||
# Gets inherited from flake in nixos mylib and passed through the module option
|
||||
|
Reference in New Issue
Block a user