gnome-control-center/panels/common/gnome-control-center.rules
Matthias Clasen 4d62e05fb0 common: Add Policykit rules for hostname setting
Allow setting the computer's pretty hostname if the user is an admin.

https://bugzilla.gnome.org/show_bug.cgi?id=679281
2012-08-22 14:16:46 +01:00

8 lines
236 B
Text

polkit.addRule(function(action, subject) {
if (action.id == "org.freedesktop.hostname1.set-static-hostname" &&
subject.local &&
subject.active &&
subject.isInGroup ("wheel")) {
return polkit.Result.YES;
}
});