Restic is a backup software, written in Go, that stands out for the method of backup that is using, called Content Defined Chunking de-duplication. It supports multiple backends and is really easy to use.
I am using resticker, a straight-forward docker container, to run restic in Production.
It allows to schedule the backups with each built-in cron support, and allows me to send notifications for successful/failed backups.
Resticker currently does not support Prometheus metrics, in order to monitor the status of the backups. So I took a manual approach to collect data using the output from official restic commands, and send them to a file, which is picked up by Node Exporter and is send to Prometheus server.
- The script is using jq to parse the json response from restic.
- The script is invoked by crontab.
docker-compose.override.yml
example is provided, on how to send the metric file to Prometheus via Node Exporter.