aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@tele2.at>2018-09-17 13:39:30 +0200
committerDavid Oberhollenzer <david.oberhollenzer@tele2.at>2018-09-19 12:22:14 +0200
commit33aa4cedff0f8d0a09f80460568c296da8d16d26 (patch)
tree5631ba6fd383808692ea5074e736d516ee8353ae /docs
parenta4dddb777777995f70c85a6cbe956faa93b01ee4 (diff)
Update documentation
Signed-off-by: David Oberhollenzer <david.oberhollenzer@tele2.at>
Diffstat (limited to 'docs')
-rw-r--r--docs/cmdline.md4
-rw-r--r--docs/defconfig.md8
-rw-r--r--docs/gcron.md62
3 files changed, 72 insertions, 2 deletions
diff --git a/docs/cmdline.md b/docs/cmdline.md
index c3945ec..e1500aa 100644
--- a/docs/cmdline.md
+++ b/docs/cmdline.md
@@ -13,6 +13,10 @@ Currently available service commands are:
* disable - disable a service. If the service is parameterized, requires the
same arguments used for enabling, to disable the specific instance of the
service.
+ * schedule - enable a gcrond service. Only available if this package is built
+ with gcrond.
+ * unschedule - disnable a gcrond service. Only available if this package is
+ built with gcrond.
* dumpscript - generate an equivalent shell script from the `exec` lines of
a service after applying all parameter substitutions.
* list - list all enabled service. A target can be specified to only list
diff --git a/docs/defconfig.md b/docs/defconfig.md
index cdfe333..3ab6563 100644
--- a/docs/defconfig.md
+++ b/docs/defconfig.md
@@ -71,6 +71,12 @@ the `sysinit` target and *before* the `network` target:
* ifcfg - static network configuration
Does the static network configuration outlined in [network.md](network.md)
+The following services are enabled by default and configured to run *after*
+the `network` target:
+
+ * gcrond - if the `gcrond` daemon is compiled with this package, this service
+ is enabled by default.
+
## Default Shutdown and Reboot Services
@@ -98,8 +104,6 @@ For the shutdown and reboot targets, the following services are executed:
type service can be enabled to manage an instace of the `hostapd` program.
* unbound - A respawn type service that manages an instance of the `unbound`
name resolver.
- * usyslogd - A respawn type service that manages an instance of the `usyslogd`
- syslogd implementation that is part of this package.
* hwclock - If the system has a hardware clock, this service can restore the
kernels clock from the hardware at bootup, between the `vfs` and `sysinit`
targets.
diff --git a/docs/gcron.md b/docs/gcron.md
new file mode 100644
index 0000000..4327083
--- /dev/null
+++ b/docs/gcron.md
@@ -0,0 +1,62 @@
+# Gcron
+
+Gcron is a small daemon that executes batch commands once a certain
+condition is met.
+
+In a typical installation, it reads configuration files from `/etc/gcron.d`.
+If used together with the init system in this package, the `service` command
+can be used to administer symlinks in that directory, pointing
+to `/usr/share/init/<name>.gcron`.
+
+Each file in the configuration directory represents a single scheduled batch
+job. The syntax and most of the keywords are similar to `initd` service files
+(See [services.md](services.md)).
+
+## Cron Style Patterns
+
+The following keywords can be used to specify classic cron style patterns for
+when a job should be run:
+
+ * `hour`
+ * `minute`
+ * `dayofmonth`
+ * `dayofweek`
+ * `month`
+
+For each of those keywords, a comma separated sequence of times can be
+specified. Time ranges can be specified using the syntax `<start>-<end>`,
+or using `*` for every possible value. A sequence (either range or star)
+can be suffixed with `/<step>` to specify an increment.
+For instance, `minute */5` means every five minutes and `minute 15-30/2`
+means every two minutes between quarter past and half past.
+
+In addition to numeric values, the keywords `dayofweek` and `month` allow
+specifying 3 letter, uppercase week day and moth names such as `MON`, `TUE`,
+etc and `JAN`, `FEB`, ...
+
+The job is only run when all specified conditions are met. Omitting a field
+is the same as specifying `*`.
+
+## Named Intervals
+
+Alternatively to the above, the keyword `interval` can be used. The following
+intervals can be specified:
+
+ * `yearly` or `annually` means on every January the first at midnight.
+ * `monthly` means on every first of the month at midnight.
+ * `weekly` means every Sunday at midnight.
+ * `daily` means every day at midnight.
+ * `hourly` means every first minute of the hour.
+
+## Command Specification
+
+To specify *what* should be done once the condition is met, the following
+keywords can be used:
+
+ * `exec` - the command to run. Multiple commands can be grouped
+ using curly braces.
+ * `user` - a user name or ID to set before running the commands.
+ * `group` - a group name or ID to set before running the commands.
+ * `tty` - similar to init service files, the controlling tty or output file
+ for the batch commands. Like init service files, the `truncate` keyword
+ can be used.