from my Manjaro I administrate my Rasperry Pis. Unfortunately it already happened that I accidentally restarted my local system instead of the remote system.
Under Debian/Ubuntu or Raspbian molly-guard works very well.
Unfortunately, molly-guard doesn’t seem to work locally on my Manjaro, even though I changed the config:
# molly-guard settings
# when set, causes the 30-query-hostname script to always ask for the
# hostname, even if no SSH session was detected.
# when set, causes the 30-query-hostname script to ask for the fully-qualified
# hostname, rather than the short name
is performed after the sudo password prompt without asking for the hostname.
What am I doing wrong?
Do I perhaps have a way elsewhere to set up the reboot of my machine via the console with a security prompt?
I have already tested it with Manjaro XFCE and Manjaro KDE, with the same result.
Because molly-guard is just a simple helper script, just like for example manjaro-chroot. It is just a helper to setup such a simple guard. You can do it also without it pretty easy, just write some functions and add aliase, thats it.
The only source I found is the one from debian, so I conclude it is made with debian in mind, just like manjaro-chroot is made with manjaro in mind.
It is pretty much this script: File: shutdown.in | Debian Sources 126 lines of code. I don’t understand why you need to use exactly this, but well, everyone has different habits.