cron: add procd listeners for crontabs
Add procd file listeners to check files in `/etc/crontabs/`.
Also unified a bit the function style.
Signed-off-by: Paul Spooren <mail@aparcar.org>
(cherry picked from commit cbf69fb2ad)
This commit is contained in:
committed by
John Crispin
parent
56f66be113
commit
38eee4da94
@@ -29,10 +29,12 @@ start_service () {
|
||||
|
||||
procd_open_instance
|
||||
procd_set_param command "$PROG" -f -c /etc/crontabs -l "${loglevel:-5}"
|
||||
for crontab in /etc/crontabs/*; do
|
||||
procd_set_param file "$crontab"
|
||||
done
|
||||
procd_close_instance
|
||||
}
|
||||
|
||||
service_triggers()
|
||||
{
|
||||
service_triggers() {
|
||||
procd_add_validation validate_cron_section
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user