Available wake up checks

The following checks for wake up times are currently implemented. Each of them is described with its available configuration options and required optional dependencies.

Calendar

Determine wake up times from calendar events.

Determines next wake up time from an iCalendar file. The next event that starts after the current time is chosen as the next wake up time.

Remember that updates to the calendar can only be reflected in case the system currently running. Changes to the calendar made while the system is sleeping will obviously not trigger an earlier wake up.

Requires

Options

url

The URL to query

timeout

Timeout for executed requests in seconds. Default: 5.

username

Optional user name to use for authenticating at a server requiring authentication. If used, also a password must be provided.

password

Optional password to use for authenticating at a server requiring authentication. If used, also a user name must be provided.

Command

Determine wake up times from an external command.

The called command must return a timestamp in UTC or nothing in case no wake up is planned.

The command always has to succeed. If something is printed on stdout by the command, this has to be the next wake up time in UTC seconds.

The command is executed as is using shell execution. Beware of malicious commands in obtained configuration files.

Options

command

The command to execute including all arguments

File

Scheduled wake up from file contents.

Determines the wake up time by reading a file from a configured location. The file has to contain the planned wake up time as an int or float in seconds UTC.

Options

path

path of the file to read in case it is present

Periodic

Schedule periodic wake ups.

Always schedules a wake up at a specified delta from now on. Can be used to let the system wake up every once in a while, for instance, to refresh the calendar used in the Calendar check.

Options

unit

A string indicating in which unit the delta is specified. Valid options are: microseconds, milliseconds, seconds, minutes, hours, days, weeks.

Allowed values: microseconds, milliseconds, seconds, minutes, hours, days, weeks.

value

The value of the delta as a float.

SystemdTimer

Check for systemd timer schedules.

Ensures that the system is active when a systemd timer is scheduled to run next.

Options

match

A regular expression selecting the systemd timers to check. This expression matches against the names of the timer units, for instance logrotate.timer. Use systemctl list-timers to find out which timers exist.

XPath

Determine wake up times from XPath expressions.

A generic check which queries a configured URL and expects the reply to contain XML data. The returned XML document is parsed using a configured XPath expression that has to return timestamps UTC (as strings, not elements). These are interpreted as the wake up times. In case multiple entries exist, the soonest one is used.

Requires

Options

xpath

The XPath query to execute. Must always return number strings or nothing.

url

The URL to query

timeout

Timeout for executed requests in seconds. Default: 5.

username

Optional user name to use for authenticating at a server requiring authentication. If used, also a password must be provided.

password

Optional password to use for authenticating at a server requiring authentication. If used, also a user name must be provided.

XPathDelta

Determine wake up times from XPath delta expressions.

Comparable to XPath, but expects that the returned results represent the wake up time as a delta to the current time in a configurable unit.

This check can for instance be used for tvheadend with the following expression:

//recording/next/text()

Requires

Options

unit

A string indicating in which unit the delta is specified. Valid options are: microseconds, milliseconds, seconds, minutes, hours, days, weeks. Default: minutes.

Allowed values: microseconds, milliseconds, seconds, minutes, hours, days, weeks.

xpath

The XPath query to execute. Must always return number strings or nothing.

url

The URL to query

timeout

Timeout for executed requests in seconds. Default: 5.

username

Optional user name to use for authenticating at a server requiring authentication. If used, also a password must be provided.

password

Optional password to use for authenticating at a server requiring authentication. If used, also a user name must be provided.