Compare commits

...

2 Commits

Author SHA1 Message Date
kevin a30324bc4c add go2rtc 2024-04-13 11:00:22 +08:00
kevin 4137379d77 update v4l2rtspserver 2024-04-13 10:00:49 +08:00
5 changed files with 62 additions and 1 deletions

View File

@ -168,6 +168,7 @@ A collection of delicious docker recipes.
- [x] ffmpeg
- [x] ffmpeg-arm
- [x] ffserver :beetle:
- [x] alexxit/go2rtc :camera:
- [x] icecast :musical_note:
- [x] live555 :camera:
- [x] minidlna

17
go2rtc/README.md Normal file
View File

@ -0,0 +1,17 @@
go2rtc
======
[go2rtc][1] is a ultimate camera streaming application with support RTSP, RTMP,
HTTP-FLV, WebRTC, MSE, HLS, MP4, MJPEG, HomeKit, FFmpeg, etc.
## up and running
```bash
$ mkdir -p data
$ wget -P data https://download.blender.org/peach/bigbuckbunny_movies/BigBuckBunny_320x180.mp4
$ vi data/go2rtc.yaml
$ docker compose up -d
$ curl http://127.0.0.1:1984
```
[1]: https://github.com/AlexxIT/go2rtc

29
go2rtc/data/go2rtc.yaml Normal file
View File

@ -0,0 +1,29 @@
api:
listen: ":1984"
#username: "admin"
#password: "pass"
rtsp:
listen: ":8554"
#username: "admin"
#password: "pass"
#default_query: "video&audio"
webrtc:
listen: ":8555"
streams:
bunny: "ffmpeg:BigBuckBunny_320x180.mp4"
#usbcam: "ffmpeg:device?video=0&video_size=1280x720#video=h264"
#publish:
#bunny: "rtmps://xxx.rtmp.youtube.com/live2/xxxx-xxxx-xxxx-xxxx-xxxx"
log:
level: info
api: trace
exec: debug
ngrok: info
rtsp: warn
streams: error
webrtc: fatal

14
go2rtc/docker-compose.yml Normal file
View File

@ -0,0 +1,14 @@
version: "3.8"
services:
go2rtc:
image: alexxit/go2rtc
ports:
- "1984:1984"
- "8554:8554"
- "8555:8555"
volumes:
- ./data:/config
#devices:
# - /dev/video0
#privileged: true
restart: unless

View File

@ -7,7 +7,7 @@ v4l2rtspserver
```bash
$ docker-compose up -d
$ vlc rtsp://127.0.0.1/live
$ vlc --network-caching=50 --rtsp-tcp rtsp://127.0.0.1/live
$ ffmpeg -rtsp_transport tcp -i rtsp://127.0.0.1/live -acodec copy -vcodec copy -t 60 cctv.mp4
$ vlc cctv.mp4
```