I have this line in /etc/crontab:
30 23 * * * geoff /usr/local/bin/fp.pl
which executes the program every day at 2330. The script terminates by
executing system 'sudo systemctl start poweroff.target';
Generally this works as expected.
However, when I realize that the shutdown happened too soon, and I
restart the system, it re-executes the script.
Any suggestions as to where I've gone wrong?
Thanks.