#! /bin/bash
#
################
#pkill avconv 
#pkill ffmpeg
pkill ezstream
pkill icecast
################
#
#############
rm -r /tmp/*
#############
#
sleep 1
#
echo -e "\e[0m"
echo "########################"
echo -e "\e[1;32mIniciando IceCast2\e[0m"
echo "########################"
#
icecast </dev/null &> /dev/null -c Live_AutoDJ.xml -b
#
sleep 1
#
echo -e "\e[0m"
echo "###########################"
echo -e "\e[1;32mIniciando o EzStream N1\e[0m"
echo "###########################"
#
ezstream </dev/null &> /dev/null -q -c ezstream_Local_mp3.xml &
#
#sleep 1
#
#echo -e "\e[0m"
#echo "##################################"
#echo -e "\e[1;32mIniciando o ffmpeg com icecast\e[0m"
#echo "##################################"
#
#avconv -loglevel quiet -i http://localhost:8000/live -ac 2 -b:a 96k -c:a libvorbis \
#
#avconv -loglevel quiet -i http://localhost:8000/live -ac 2 -q:a 2 -c:a libvorbis \
#
#avconv -loglevel quiet -i http://localhost:8000/live -c:a copy -f mp3 \
#
#avconv -loglevel quiet -i http://localhost:8000/live -ac 2 -b:a 128k -c:a libmp3lame \
#       -legacy_icecast 1 -content_type audio/mpeg \
#       -ice_name "Radio M7B" -ice_genre "Diversos" \
#       -ice_description "Descricao" \
#       -ice_url "http://m7bradio.listen2myradio.com" \
#       icecast://source:001001@78.129.190.50:35108/stream.mp3 &
#
echo -e "\e[0m"
#