Duncaen / OpenDoas

A portable fork of the OpenBSD `doas` command
Other
623 stars 35 forks source link

Failed to power off system via logind: Interactive authentication required. #105

Closed ghost closed 1 year ago

ghost commented 1 year ago
$[~]$ poweroff
Failed to power off system via logind: Interactive authentication required.

I've researched about this & came to know that sudo & polkit were requesting authentication from user. With polkit, it's little challenging to allow a user to do systemctl level operations. But with sudo, it was as easy as echo "youname ALL = NOPASSWD: /bin/systemctl" >> /etc/sudoers.d/sysctl. How to do this on opendoas ?

ghost commented 1 year ago

Oh okay. There's a poweroff.target service that I started it's working now. Not related to doas at all.