I have some ip cameras recording on cifs share mounted in HA under /media. Unfortunately sometimes the cameras stop recording or start splitting the recordings in unwanted sized.
I’d like to have an automation confirm that a file has been created, under a specific path, in the last hour and such file has a size greater than X Mb.
command is looking for files mp4 written in the last 60 mins and with a size over 100mb - it will display ‘found’ for any occurrence - but since payload_on need an exact match, I’m using | head -n 1' to catch only the first line