home-automation-home-assistant/automations/backups.yaml
2019-01-26 00:16:30 +01:00

35 řádky
1017 B
YAML

- alias: Backup Error
trigger:
- platform: state
entity_id: binary_sensor.backup_error_occured
to: 'on'
action:
- service: notify.telegram_group
data:
title: '*Backup-Problem:*'
message: 'Es gab Fehler beim *Erstellen* des Backups. Bitte prüfen!'
- service: notify.telegram_group
data:
message: 'Anbei die Log-Datei :)'
data:
document:
file: /backuplogs/run.err.log
caption: Backup Creation Log
- alias: Backup Sync Error
trigger:
- platform: state
entity_id: binary_sensor.backup_sync_error_occured
to: 'on'
action:
- service: notify.telegram_group
data:
title: '*Backup-Problem:*'
message: 'Es gab Fehler beim *Synchronisieren* des Backups. Bitte prüfen!'
- service: notify.telegram_group
data:
message: 'Anbei die Log-Datei :)'
data:
document:
file: /backuplogs/sync.out.log
caption: Backup Sync Log