Add-on: Home Assistant Google Drive Backup

That is how I do it :

sensor:

  - platform: template
    sensors:
      last_backup:
        friendly_name: "Last Backup"
        value_template: "{{state_attr('sensor.snapshot_backup', 'last_snapshot')}}"

automation :

- id: '1593338157847'
  alias: Last backup
  description: ''
  trigger:
  - entity_id: sensor.last_backup
    platform: state
  condition:
    - condition: numeric_state
      entity_id: sensor.time_online
      above: 3  
  action:
  - data:
      message: Backed up
    service: notify.notifier_doorbell

Notice the use of the condition sensor.time_online ( the uptime integration) to not get a notification when HA restarts.

Thanks both, this makes more sense.
ive updated my config, will wait for the next update to run

This morning I discovered that my system was trying to create a full backup (~85Gb due to CCTV footage that would normally be excluded) rather than the usual partial one. It seems that the last update of this add-on erased my backup settings and set them to default. Has anyone else had the same?

So the automation ran, but it gave me 2 notifications from the android app?

- alias: Snapshot made notification
  initial_state: 'on'
  trigger:
    - platform: state
      entity_id: sensor.last_backup
  condition:
    - condition: numeric_state
      entity_id: sensor.ha_time_online
      above: 3
  action:
    - service: persistent_notification.create
      data_template:
        title: Snapshot made
        message: >-
          {{ states.sensor.snapshot_backup.attributes.snapshots[3].name }}
          Snapshots on Drive: {{ states.sensor.snapshot_backup.attributes.snapshots_in_google_drive }}
          Snapshots stored locally: {{ states.sensor.snapshot_backup.attributes.snapshots_in_hassio }}
    - service: notify.mobile_app_oneplus7pro
      data_template:
        title: Snapshot Update
        message: |
          {{ states.sensor.snapshot_backup.attributes.snapshots[3].name }}
          Snapshots on Drive: {{ states.sensor.snapshot_backup.attributes.snapshots_in_google_drive }}
          Snapshots stored locally: {{ states.sensor.snapshot_backup.attributes.snapshots_in_hassio }}- alias: Snapshot made notification
  initial_state: 'on'
  trigger:
    - platform: state
      entity_id: sensor.last_backup
  condition:
    - condition: numeric_state
      entity_id: sensor.ha_time_online
      above: 3
  action:
    - service: persistent_notification.create
      data_template:
        title: Snapshot made
        message: >-
          {{ states.sensor.snapshot_backup.attributes.snapshots[3].name }}
          Snapshots on Drive: {{ states.sensor.snapshot_backup.attributes.snapshots_in_google_drive }}
          Snapshots stored locally: {{ states.sensor.snapshot_backup.attributes.snapshots_in_hassio }}
    - service: notify.mobile_app_oneplus7pro
      data_template:
        title: Snapshot Update
        message: |
          {{ states.sensor.snapshot_backup.attributes.snapshots[3].name }}
          Snapshots on Drive: {{ states.sensor.snapshot_backup.attributes.snapshots_in_google_drive }}
          Snapshots stored locally: {{ states.sensor.snapshot_backup.attributes.snapshots_in_hassio }}

Yes. It seems the sensor changes twice within about 2 minutes. I don’t know if it is a bug or intentional.

Just noticed that my backups since 4 days ago went from 280 mb in size to 17 gb. Anyone else seen this?

Mine are looking fine. But I moved my database off my pi, so that could have something to do with it.

You could open the .tar and see what is eating up the space.

Have latest AddOn and no problems at all on latest HA (moment of written)

Seems to be the adb addon. Removed it from backup and back to normal.

Hi, firstly thanks for this amazing add on! I just moved my home assistant instance from an Ubuntu server laptop running in docker to a raspberry pi 4 using this add on. However now it still says ‘docker: true’ and the operating system info still relates to the old machine. Am I now running home assistant in docker on the raspberry pi? If not how do I get the system info to update? I’ve tried a restart of ha and full reboot of the pi but nothings updated! Sorry if these are stupid questions, this is the first time I’ve moved home assistant! On a plus note everything restored perfectly! Cheers

Unless you run Home Assistant in a venv (HA Core), you always have docker.

Ah ok, that makes sense then! Thanks for the reply!

added the repo and installed and ran into “Failed to install addon, [object Object]”

I am noticing the backup actually performs 10 mins after the set time in config. Not a big deal. I just have to adjust my redundant backup script to start a few minutes later so it doesn’t miss today’s. The backup file is only 550kb.

What is your problem today ? First you post a totally inappropriate message in the tasmoadmin topic, now here ?

1 Like

I think I get what you’re saying, it’s about Home Assistant broadly but I’ll try to be helpful. Home Assistant, in general, is very hard to use. Mostly
that’s because it’s an open source project run by volunteers. This means people generally can’t dedicate a lot of time to “polish” and usability. To make things worse, the community using it is very technically knowledgeable (think software engineers) which means they’re pretty tolerant of difficult setup experiences. Hell, I’ve been involved with software dev going on 15 years now and it still gets me frustrated. This add-on is no different, though I like to think it’s at least a little less confusing.

Unfortunately, that’s just where the home automation scene is right now. HA is infinitely configurable, but that’s comes at the cost of useability. I think people get drawn in by HA’s sexy screenshots, grand promises, and cheap hardware but are unaware of the hours or days it takes to get something useful working. And the constant maintenance. Even when set up well, it can be pretty unreliable. The barrier to get up and running is high. You might be better served by using something more “turn-key” like a smartthings hub that is much less flexible but much easier to use. Someday HA might get there but it’s not today or any time soon.

Say what??? It pretty much works out-of-the-box now with no configuration… That is certainly the goal.

Hi , have someone problem with Internal Server Error (#500) ? Cannot authenticate :confused:

Yeah, seems like the server might be down again. Bad timing for me :stuck_out_tongue: