Skip to content

Instantly share code, notes, and snippets.

@BruceWind
Last active August 12, 2021 02:51
Show Gist options
  • Save BruceWind/53bfdd0e059a5c14f7a8f209b8b13785 to your computer and use it in GitHub Desktop.
Save BruceWind/53bfdd0e059a5c14f7a8f209b8b13785 to your computer and use it in GitHub Desktop.
A RTP server hold RTP stream I require.
docker run -it --rm --name easydrawin -p 5004-5007:5004-5007/udp -p 8554:8554 -p 554:554 -p 7777:7777 -p 10008:10008 alextheloafer/easydarwin

By the time it established, you are able to push RTP stream into it. Open url http://localhost:10008/ to look into it.

Other infomation or guidance in there: EasyDarwin.


When you make your pusher such as Android phone pushed steam into your docker, you will get logs such as:

<<<<<<<<<<< request[OPTIONS] <<<<<<<<<<<<<
OPTIONS rtsp://172.26.201.116:554/test RTSP/1.0
CSeq: 1
User-Agent: com.pedro.rtsp 2.0.6


>>>>>>>>>>>>> response[OPTIONS] >>>>>>>>>>>>>
RTSP/1.0 200 OK
CSeq: 1
Session: SkJ077ZeK
Public: DESCRIBE, SETUP, TEARDOWN, PLAY, PAUSE, OPTIONS, ANNOUNCE, RECORD


<<<<<<<<<<< request[ANNOUNCE] <<<<<<<<<<<<<
ANNOUNCE rtsp://172.26.201.116:554/test RTSP/1.0
Content-Type: application/sdp
CSeq: 2
User-Agent: com.pedro.rtsp 2.0.6
Session: SkJ077ZeK
Content-Length: 435

v=0
o=- 0 0 IN IP4 127.0.0.1
s=Unnamed
i=N/A
c=IN IP4 172.26.201.116
t=0 0
a=recvonly
m=video 0 RTP/AVP 96
a=rtpmap:96 H264/90000
a=fmtp:96 packetization-mode=1; sprop-parameter-sets=Z2QAHqy0DwKNKQUCAgbQoTU=,aO4G8sA=
a=control:streamid=0
m=audio 0 RTP/AVP 97
a=rtpmap:97 MPEG4-GENERIC/32000/2
a=fmtp:97 profile-level-id=1; mode=AAC-hbr; config=1290; sizelength=13; indexlength=3; indexdeltalength=3
a=control:streamid=1

>>>>>>>>>>>>> response[ANNOUNCE] >>>>>>>>>>>>>
RTSP/1.0 200 OK
CSeq: 2
Session: SkJ077ZeK


<<<<<<<<<<< request[SETUP] <<<<<<<<<<<<<
SETUP rtsp://172.26.201.116:554/test/streamid=0 RTSP/1.0
Transport: RTP/AVP/TCP;unicast;interleaved=0-1;mode=record
CSeq: 3
User-Agent: com.pedro.rtsp 2.0.6
Session: SkJ077ZeK


>>>>>>>>>>>>> response[SETUP] >>>>>>>>>>>>>
RTSP/1.0 200 OK
CSeq: 3
Session: SkJ077ZeK
Transport: RTP/AVP/TCP;unicast;interleaved=0-1;mode=record


<<<<<<<<<<< request[SETUP] <<<<<<<<<<<<<
SETUP rtsp://172.26.201.116:554/test/streamid=1 RTSP/1.0
Transport: RTP/AVP/TCP;unicast;interleaved=2-3;mode=record
CSeq: 4
User-Agent: com.pedro.rtsp 2.0.6
Session: SkJ077ZeK


>>>>>>>>>>>>> response[SETUP] >>>>>>>>>>>>>
RTSP/1.0 200 OK
CSeq: 4
Session: SkJ077ZeK
Transport: RTP/AVP/TCP;unicast;interleaved=2-3;mode=record


<<<<<<<<<<< request[RECORD] <<<<<<<<<<<<<
RECORD rtsp://172.26.201.116:554/test RTSP/1.0
Range: npt=0.000-
CSeq: 5
User-Agent: com.pedro.rtsp 2.0.6
Session: SkJ077ZeK


>>>>>>>>>>>>> response[RECORD] >>>>>>>>>>>>>
RTSP/1.0 200 OK
CSeq: 5
Session: SkJ077ZeK


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment