#!/bin/bash

# go2rtc 快速启动脚本
# 用于将 RTSP 摄像头转换为 WebRTC 流

cd "$(dirname "$0")"

echo "================================"
echo "  go2rtc 流媒体服务"
echo "================================"
echo ""
echo "启动服务..."
echo ""
echo "服务地址:"
echo "  - 管理界面: http://localhost:1984"
echo "  - WebRTC:   http://localhost:1984/api/webrtc?src=camera1"
echo "  - HLS:      http://localhost:1984/api/stream.m3u8?src=camera1"
echo ""
echo "按 Ctrl+C 停止服务"
echo "================================"
echo ""

./go2rtc -config go2rtc.yaml
