Outils pour utilisateurs

Outils du site


radio.sh
#!/bin/sh
export PATH=“/opt/bin:/opt/sbin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/syno/sbin:/usr/syno/bin:/usr/local/sbin:/usr/local/bin”
echo “kill ices…”
pid=$(ps aux | grep /ices | grep -v grep | awk '{print $2}')
kill $pid
echo “kill icecast…”
pid=$(ps aux | grep icecast.xml | grep -v grep | awk '{print $2}')
kill $pid
echo “mettre la playlist à jour”
find /volume1/music/ -name “*.mp3” -o -name “*.ogg” > /opt/share/icecast/web/stream.ogg/pls.m3u
chmod 644 /opt/share/icecast/web/stream.ogg/pls.m3u
echo “demarrage d'icecast…”
su - nobody -c “/opt/bin/icecast -b -c /opt/etc/icecast.xml”
echo “demarrage d'ices…”
/opt/bin/ices -c /opt/etc/ices.conf -F /opt/share/icecast/web/stream.ogg/pls.m3u
# fin 
radio.sh.txt · Dernière modification: 2022/02/18 18:20 (modification externe)