Skip to content

Instantly share code, notes, and snippets.

@tteck
Created December 5, 2020 18:18
Show Gist options
  • Save tteck/b2c27756e10765390f86f1f2f62872f4 to your computer and use it in GitHub Desktop.
Save tteck/b2c27756e10765390f86f1f2f62872f4 to your computer and use it in GitHub Desktop.
Create a full snapshot at a given time every day. (Created by vori)
blueprint:
name: Automated Snapshot
description: Create a full snapshot at a given time every day.
domain: automation
input:
trigger_time:
name: Snapshot creation time
selector:
time:
send_notification:
name: Send notification
description: Sends a notification to a device if enabled.
selector:
boolean:
default: false
notify_device:
name: Device to notify
description: Device needs to run the official Home Assistant app to receive notifications.
selector:
device:
integration: mobile_app
default: ""
mode: single
max_exceeded: silent
variables:
send_notification: !input send_notification
trigger:
- platform: time
at: !input trigger_time
action:
- service: hassio.snapshot_full
data:
name: "Automated backup {{ now().strftime('%F') }}"
- choose:
- conditions: "{{ send_notification }}"
sequence:
- device_id: !input notify_device
domain: mobile_app
type: notify
message: "Home Assistant full backup created. {{ now().strftime('%F') }}"
title: Automated Backup
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment