2011-11-02 15:30:35 +00:00
|
|
|
cdist-type__cron(7)
|
|
|
|
===================
|
|
|
|
Steven Armstrong <steven-cdist--@--armstrong.cc>
|
|
|
|
|
|
|
|
|
|
|
|
NAME
|
|
|
|
----
|
|
|
|
cdist-type__cron - installs and manages cron jobs
|
|
|
|
|
|
|
|
|
|
|
|
DESCRIPTION
|
|
|
|
-----------
|
|
|
|
This cdist type allows you to manage entries in a users crontab.
|
|
|
|
|
|
|
|
|
|
|
|
REQUIRED PARAMETERS
|
|
|
|
-------------------
|
|
|
|
user::
|
|
|
|
The user who's crontab is edited
|
|
|
|
command::
|
|
|
|
The command to run.
|
|
|
|
|
|
|
|
|
|
|
|
OPTIONAL PARAMETERS
|
|
|
|
-------------------
|
|
|
|
state::
|
|
|
|
Either present or absent. Defaults to present.
|
|
|
|
minute::
|
|
|
|
See crontab(5). Defaults to *
|
|
|
|
hour::
|
|
|
|
See crontab(5). Defaults to *
|
|
|
|
day_of_month::
|
|
|
|
See crontab(5). Defaults to *
|
|
|
|
month::
|
|
|
|
See crontab(5). Defaults to *
|
|
|
|
day_of_week::
|
|
|
|
See crontab(5). Defaults to *
|
2012-03-10 13:07:13 +00:00
|
|
|
raw::
|
|
|
|
Take whatever the user has given instead of time and date fields.
|
|
|
|
If given, all other time and date fields are ignored.
|
|
|
|
Can for example be used to specify cron EXTENSIONS like reboot, yearly etc.
|
2012-03-10 13:08:57 +00:00
|
|
|
See crontab(5) for the extensions if any that your cron implementation
|
|
|
|
implements.
|
2011-11-02 15:30:35 +00:00
|
|
|
|
|
|
|
|
|
|
|
EXAMPLES
|
|
|
|
--------
|
|
|
|
|
|
|
|
--------------------------------------------------------------------------------
|
2012-03-09 19:05:50 +00:00
|
|
|
# run Monday to Saturday at 23:15
|
|
|
|
__cron some-id --user root --command "/path/to/script" \
|
|
|
|
--hour 23 --minute 15 --day_of_week 1-6
|
|
|
|
|
|
|
|
# run on reboot
|
|
|
|
__cron some-id --user root --command "/path/to/script" \
|
2012-03-10 13:07:13 +00:00
|
|
|
--raw @reboot
|
2011-11-02 15:30:35 +00:00
|
|
|
|
|
|
|
# remove cronjob
|
|
|
|
__cron some-id --user root --command "/path/to/script" --state absent
|
|
|
|
--------------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
|
SEE ALSO
|
|
|
|
--------
|
|
|
|
- cdist-type(7)
|
|
|
|
- crontab(5)
|
|
|
|
|
|
|
|
|
|
|
|
COPYING
|
|
|
|
-------
|
|
|
|
Copyright \(C) 2011 Steven Armstrong. Free use of this software is
|
|
|
|
granted under the terms of the GNU General Public License version 3 (GPLv3).
|