Skip to content

Commit e705639

Browse files
committed
cron,services/index: Multiple changes.
* cron: - link to "cron" page on Wikipedia. - provide brief introduction. - mention crontab(1). - mention the `crond` service. - remove reference to `runwhen`, which is not packaged. - expand description of `snooze` package. * services/index: - mention option of using `cron` to run something regularly, link to "cron" section.
1 parent 5204acf commit e705639

File tree

2 files changed

+25
-7
lines changed

2 files changed

+25
-7
lines changed

src/config/cron.md

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,27 @@
11
# Cron
22

3-
Void Linux comes without a default cron daemon, you can choose one of multiple
4-
cron implementations, by installing the package and enabling the system service.
3+
[cron](https://en.wikipedia.org/wiki/Cron) is a daemon for running programs at
4+
regular intervals. The programs and intervals are specified in a `crontab` file,
5+
which can be edited with [crontab(1)](https://man.voidlinux.org/crontab.1).
6+
Running `crontab -e` as the superuser will edit the system crontab; otherwise,
7+
it will edit the crontab for the current user.
58

6-
Available choices include [cronie](https://github.com/cronie-crond/cronie/),
9+
By default, a cron daemon is not installed. However, multiple cron
10+
implementations are available, including
11+
[cronie](https://github.com/cronie-crond/cronie/),
712
[dcron](http://www.jimpryor.net/linux/dcron.html),
813
[fcron](http://fcron.free.fr/) and more.
914

10-
As alternative to the standard cron implementations you can use something like
11-
[snooze](https://github.com/leahneukirchen/snooze) or
12-
[runwhen](https://code.dogmap.org/runwhen/) which go hand in hand with service
13-
supervision.
15+
Once you have chosen and installed an implementation,
16+
[enable](./services/index.md#enabling-services) the `crond` service, which is a
17+
symlink to the actual service (e.g. `dcron`). If you install several
18+
implementations, you can choose which one to use via
19+
[xbps-alternatives(1)](https://man.voidlinux.org/xbps-alternatives.1); this will
20+
alter the `crond` symlink appropriately. Implementation documentation will be
21+
available in [crond(8)](https://man.voidlinux.org/crond.8).
22+
23+
As an alternative to the standard cron implementations, you can use
24+
[snooze(1)](https://man.voidlinux.org/snooze.1) together with the
25+
`snooze-hourly`, `snooze-daily`, `snooze-weekly` and `snooze-monthly` services,
26+
which are provided by the `snooze` package for this purpose. Each of these
27+
services execute scripts in the respective `/etc/cron.*` directories.

src/config/services/index.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ Some advantages of using runit include:
1212
- a reliable logging facility for services, where the log service stays up as
1313
long as the relevant service is running and possibly writing to the log.
1414

15+
If you don't need a program to be running constantly, but would like it to run
16+
at regular intervals, you might like to consider using a [cron
17+
daemon](../cron.md).
18+
1519
## Section Contents
1620

1721
- [Per-User Services](./user-services.md)

0 commit comments

Comments
 (0)