I’ve modified the media_source.py like this:
media_source.py
"""Create the disk backed EventMediaStore."""
media_path = hass.config.path(MEDIA_PATH)
if DOMAIN in hass.config.media_dirs:
media_path = hass.config.media_dirs[DOMAIN]
_LOGGER.debug(media_path)
if I have in my media_dirs configuration (totally optional) an entry “nest” like this:
configuration.yaml
Is there some way to setup an automation to regularly delete the Nest Media files? I am running on a Raspberry Pi with somewhat limited storage(120GB SSD) and just don’t want to fill it up with video files. It’s fine if there is not built-in setting to configure but if there was a service to call to delete media I’d be fine setting that up myself to run. Perhaps there is a script I can create and call?
If media_dirs is supposed to be a way that integrations should let users configure storage for their needs, then feel free to contribute this to the actual nest integration.
Just jumping in as i’m seeing a similar issue - one of the suggestions here is to just delete the files, but ‘just deleting’ the files doesn’t remove the object references from HA itself - so what is the solution to purge correctly?
You can delete the internal storage for the references in json if you are feeling lucky. There is not a feature for what you’re looking for. I guess just ignore it since you have it off anyway?
Yup, seen that, removed it as a test…it gets re-created with events referenced again after a HA restart.
Is it pulled the event data from Google perhaps?
ok, interesting -
Using the partner connections dashboard, disabling screenshots/clips, turning off HA, removing the “nest.event_media” file from .storage, starting HA again, the media folder within the HA WebGUI still shows the nest object, but with a ‘no items’ status, with the “nest.event_media” file NOT being re-created.
So it must have been pulling from Google?
I never had those snapshots in that nest folder, already have the nest integration active like for 2 years , on last backup I noticed an increase of the backup file… And there were a lot of snapshots now…
Did this behavior changed?
Anyway, as suggested I now disabled:
Based on the events you’ve selected to share from this device, allow nest_api to access camera snapshots
I just switched to the Google Nest integration from the Nest integration with a recent notification that Nest Dev accounts were going to go away at the end of the year. So, from reading this thread, the integration should ultimately delete these files on its own once it reaches a limit?
Noticed the same today when trying to find out why my backups were getting large. The nest media folder had grown to 2GB. For now, I used boomam suggestion above to disable the screenshots/clips.