feat: run user defined scripts when alerts go into given states

Executing the script

cctv will parse and call the shebang of the script passing the file as the last argument, defaulting to /usr/bin/env bash. This means the script can be anything, and is not limited to Bash. It also does not have to be executable.

King

To make sure we aren't duplicating script executions or desktop notifications, each instance of cctv will now try to connect to an abstract socket called cctv. The instance that holds the connection is the lead and will take these actions. The remaining instances will continue to try to connect to socket in case the lead dies. The first instance to manage to connect to the socket becomes the lead.

Also sneaks in Error mode state support that closes #9 (closed)

Edited by caferen

Merge request reports

Loading