Files
main/network/share/rsync/comar/service.py
T
2015-07-16 02:50:18 +03:00

23 lines
557 B
Python

# -*- coding: utf-8 -*-
serviceType = "server"
serviceDesc = _({"en": "RSync Daemon",
"tr": "RSync Servisi"})
serviceConf = "rsyncd"
from comar.service import *
@synchronized
def start():
startService(command="/usr/bin/rsync",
args="--daemon %s" % config.get("RSYNC_OPTS", ""),
pidfile="/run/rsyncd.pid",
donotify=True)
@synchronized
def stop():
stopService(pidfile="/run/rsyncd.pid",
donotify=True)
def status():
return isServiceRunning("/run/rsyncd.pid")