frigate/uptime-go/uptime/ping/video_ping.go

11 lines
205 B
Go
Raw Normal View History

package ping
import "os/exec"
func VideoPing(url string) bool {
var cmd = exec.Command("ffprobe", "-rtsp_transport", "tcp", "-i", url, "-timeout", "10000000")
var err = cmd.Run()
return err == nil
}