gamemode/data/polkit/rules.d/gamemode.rules.in
Henrik Holst 7381d93c13 Update gamemode.rules.in
added policykit rules for a new helper to modify values in /proc/sys
2023-12-05 11:31:16 +00:00

15 lines
543 B
Plaintext

/*
* Allow users in privileged gamemode group to run cpugovctl &
* gpuclockctl without authentication
*/
polkit.addRule(function (action, subject) {
if ((action.id == "com.feralinteractive.GameMode.governor-helper" ||
action.id == "com.feralinteractive.GameMode.gpu-helper" ||
action.id == "com.feralinteractive.GameMode.cpu-helper") ||
action.id == "com.feralinteractive.GameMode.procsys-helper") &&
subject.isInGroup("@GAMEMODE_PRIVILEGED_GROUP@"))
{
return polkit.Result.YES;
}
});