phpMyStream

phpMyStream is media re-stream panel, it use FFmpeg & rtmpdump linux utilities to take source as input then publish to other server like Red5 or Wowza.

phpMyStream

phpMyStream Server Requirement

– Web Server With Apache, PHP, MySQL
– RTMPDump
– FFmpeg
– RTMP Server (Wowza, Red5, Nginx)

phpMyStream-add-stream

RTMPDump Help

FFmpeg Help

phpMyStream-settings

Make Server for phpMyStream

Install rtmpdump
# yum install gcc
# yum install openssl-devel
# wget http://rtmpdump.mplayerhq.hu/download/rtmpdump-2.2e.tar.gz
# tar xvf rtmpdump-2.2e.tar.gz
# cd rtmpdump-2.2e
# make & make install

Install FFmpeg
# yum install ffmpeg ffmpeg-devel ffmpeg-libpostproc opencore-amr

Re-Stream Commands

# rtmpdump –live -r “[Source-Input-RTMP]” -p “http://domain.tv/” -W “http://static.domain.tv/player.swf” -q | ffmpeg -i – -re -isync -acodec copy -vcodec copy -f flv “[Destination-Output-RTMP]”

# rtmpdump -r “[Source-Input-RTMP]” -p “http://www.domain.co/” -T “[Token]” -o- | ffmpeg -re -i – -isync -acodec copy -vcodec copy -f flv “[Destination-Output-RTMP]”

# ffmpeg -re -i “[Source-Input-RTMP]” -y -vcodec libx264 -acodec aac -strict -2 -ar 44100 -f flv “[Destination-Output-RTMP]”

phpMyStream set scheduled task (per minute) to process every stream that need restreaming…

* * * * * curl -s -o /dev/null http://Server-IP/phpMyStream/cron.php