[systemd-devel] Dedup timers?

Auke Kok auke-jan.h.kok at intel.com
Tue Sep 26 16:08:45 UTC 2017




On 09/25/2017 10:45 PM, Daniel Wang wrote:
> I have a number of timers that all look something like the following:
<snip>
> The boilerplate for such small things is killing me. Is there a good
> technique to replace them with something simpler?
> Maybe transient timers? What will be the drawbacks of transient timers
> comparing to regular timers?


I assume timers can be instanced as well:

hourly at .timer:

>>>>>>>

[Unit]
Description=Runs a unit every hour

[Timer]
OnCalendar=hourly
Unit=%I

<<<<<<<

But, this is totally hypothetical, I have not tested if this actually works.

Auke


More information about the systemd-devel mailing list