Configuring Polkit to allow complete control remotely

I needed the solution to the same problem on 21.04 and, after some research, come up with this. I'm pretty sure this will work on 20.04. Note that it (probably) requires a reboot and that allowed users need to me in the group "users".

gpasswd -a myuser users

cat > /etc/polkit-1/localauthority.conf.d/52-headless.conf <<EoT
[Remote sessions exemption]
Identity=unix-group:users
Action=*
ResultAny=yes
ResultInactive=yes
ResultActive=yes
EoT