2010/11/25 Tomas Mraz <tmraz(a)redhat.com>:
On Wed, 2010-11-24 at 21:56 +0100, Lennart Poettering wrote:
> That's the point of the .path unit. i.e. you can list dirs to watch. If
> a user then drop a file into one of those dirs cron gets automatically
> started.
>
> Basically, in your .path unit you'd write something like this:
>
> [Path]
> PathExists=/etc/crontab
> DirectoryNotEmpty=/etc/cron.d
> DirectoryNotEmpty=/var/spool/cron
>
> And the moment where /etc/crontab starts to exist, or somebody drops a
> file into /etc/cron.d or /var/spool/cron crond would be automatically
> started.
But what is the point of this? The /etc/crontab always exists and there
always are some files in /etc/cron.d.
Actually it's true, but in the near future all standard cron jobs
might be runned by systemd
http://0pointer.de/public/systemd-man/systemd.timer.html
It's not 100 % cron replacement now, but who knows what the future holds :)
Kind regards,
Michal