add icecast

This commit is contained in:
groni
2016-02-08 14:01:05 +01:00
parent 92d800845d
commit 69c86dc671
12 changed files with 333 additions and 2 deletions
@@ -0,0 +1,8 @@
#!/usr/bin/python
import os
def postInstall(fromVersion, fromRelease, toVersion, toRelease):
os.system("/bin/chown -R icecast:icecast /var/log/icecast")
os.system("/bin/chown -R icecast:icecast /etc/icecast")
os.system("/bin/chown -R icecast:icecast /run/icecast")
@@ -0,0 +1,27 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
from comar.service import *
serviceType = "server"
serviceDesc = _({"en": "Icecast Daemon",
"tr": "Icecast Servisi"})
@synchronized
def start():
startService(command="/usr/bin/icecast",
args="-c /etc/icecast/icecast.xml",
pidfile="/run/icecast/icecast.pid",
donotify=True,
detach=True)
@synchronized
def stop():
stopService(pidfile="/run/icecast/icecast.pid",
donotify=True)
def status():
return isServiceRunning("/run/icecast/icecast.pid")
def reload():
stopService(command="/usr/bin/icecast",
args="reload")