Re: Run scripts from rc.suspend

From: Johannes Totz <jo_at_bruelltuete.com>
Date: Thu, 04 May 2023 18:12:21 UTC
On 04/05/2023 16:59, Eugene Grosbein wrote:
> 04.05.2023 21:37, Johannes Totz wrote:
>> Hi everyone,
>>
>> /etc/rc.resume can run rc-scripts with the resume keyword.
>> /etc/rc.suspend does not have a similar feature.
>> Is there a good reason why not? Or is it just a case of nobody-asked-for-it-yet?
> 
> The latter.

Quick hack: https://reviews.freebsd.org/D39965
Works as intended.

I would use this as follows: I'm done for the day, press sleep button on 
my workstation. A new rc.suspend-script runs and sets a wake up time for 
the next morning. Then the next day the machine wakes up again, runs its 
cron jobs or whatever and is ready when I'm ready.