log stream
This commit is contained in:
parent
042ac1ff71
commit
4843373cd4
6
stream
6
stream
@ -17,5 +17,7 @@ RestreamSG) rtmp=rtmp://singapore.restream.io/live/$key ;;
|
||||
*) rtmp=rtmp://live.restream.io/live/$key
|
||||
esac
|
||||
|
||||
ffmpeg -re -y -i $in -c:v copy -c:a copy -f flv "$rtmp" ||
|
||||
echo "Error while streaming $1" >>"$log"
|
||||
set -o pipefail # to get ffmpeg's returncode
|
||||
! ffmpeg -re -y -i $in -c:v copy -c:a copy -f flv "$rtmp" |tail -n 20 >"$in.log" &&
|
||||
echo "Error while streaming $1" >>"$log" ||
|
||||
rm "$in.log" # Remove tailfile if no errors
|
||||
|
||||
Loading…
Reference in New Issue
Block a user