Schedule
schedule.toml is the calendar of timed tasks and seasonal events: a shutdown with
warnings, a message to everybody, a call to a Lua function, and the dates of events such as
Halloween.
[[task]]id = "nightly_restart"when = { every = "day", at = "04:00" }action = "shutdown"warnings = [600, 300, 60, 10]
[[event]]id = "halloween"name = "Halloween"from = "10-20"to = "11-02"| Field | Meaning |
|---|---|
[[task]] |
One per timed task: id, when (every, at, days), action and what the action needs. |
[[event]] |
One per seasonal event: id, name, from and to as MM-dd, both inclusive. |
The shipped file has the tasks as examples in comments, so none runs until the operator enables
one, and the events halloween and christmas on (Holidays). The file may be missing: the
calendar is then empty.
Validation at startup
Section titled “Validation at startup”The server stops at startup, naming the file and the entry, when:
- a key is unknown, or an
idis missing, repeated (tasks and events share the namespace) or not[a-z][a-z0-9_]*of at most 40 characters (it starts with a letter); when.everyis nothour,dayorweek,atis not a validHH:MM(or:MMforhour), ordaysnames a day that is notmontosun;- the
actionis unknown, abroadcasthas bothmessageandtextor none, aluatask has noscript, orwarningsare not descending seconds from 1 to 86400; warningsare set on a task that is not the shutdown, or atextis longer than 200 characters;- an event has a
nameof fewer than 1 or more than 60 characters,dayswithoutevery = "week", or afromortothat is not a realMM-dddate.
See also
Section titled “See also”- Schedule
event- Server configuration for the time zone
Made with ❤️ by Tom
