Merge pull request #4701 from martinpitt/networkd-polkit
hostnamed: allow networkd to set the transient hostname
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
[Allow systemd-networkd to set transient hostname]
|
||||
Identity=unix-user:systemd-network
|
||||
Action=org.freedesktop.hostname1.set-hostname
|
||||
ResultAny=yes
|
||||
@@ -0,0 +1,5 @@
|
||||
polkit.addRule(function(action, subject) {
|
||||
if (action.id == "org.freedesktop.hostname1.set-hostname" && subject.user == "systemd-network") {
|
||||
return polkit.Result.YES;
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user