diff --git a/files/process_motion_event.sh b/files/process_motion_event.sh index 6e752ac..2f18b53 100644 --- a/files/process_motion_event.sh +++ b/files/process_motion_event.sh @@ -233,9 +233,8 @@ if [ -n "${ntfy_server}" ]; then ntfy_password="$(cat "${ntfy_password_file}")" message "Sending event to ntfy server '${ntfy_server}/motion_detection' ..." if [ -n "${file}" ]; then - sleep 3 temp_file="$(mktemp /tmp/tmp.XXXXX.mkv)" - result=$(/usr/bin/ffmpeg -filter_complex '[0:v] fps=12,scale=480:-1,split [a][b];[a] palettegen [p];[b][p] paletteuse' -i "${file}" "${temp_file}" 2>&1) + result=$(/usr/bin/ffmpeg -y -filter_complex '[0:v] fps=12,scale=480:-1,split [a][b];[a] palettegen [p];[b][p] paletteuse' -i "${file}" "${temp_file}" 2>&1) return_code=$? if [ ${return_code} != 0 ]; then message "Error ${return_code} processing video file '${file}'. ${result}"