wyx087, maybe a stupied question but where do you run the script?
Is in the Docker, host computor or the NAS ?
On host computer for me.
Could be on NAS. Just reverse the rsync source/destination folders.
Not in Docker because that would involve messing with mounted folders. I’ve just got a standard HassIO “generic Linux” scripted install. Don’t even know where to change the Docker settings.
Actually, if you can modify Docker settings to mount your NAS directory. You could include this shell script as part of your snapshot automation.
Eg.
- trigger: time of day
- action:
– do a snapshot
– wait a few minutes if the snapshot service is non-blocking
– call the shell script