avahi-dnsconfd-service.py 656 B

123456789101112131415161718192021222324252627282930
  1. from comar.service import *
  2. import signal
  3. serviceType="server"
  4. serviceDesc = _({"en": "Avahi DNS Configuration Daemon",
  5. "tr": "Avahi DNS Yapılandırma Hizmeti"})
  6. PIDFILE = "/run/avahi-dnsconfd.pid"
  7. DAEMON = "/usr/sbin/avahi-dnsconfd"
  8. @synchronized
  9. def start():
  10. startDependencies("avahi")
  11. startService(command=DAEMON,
  12. args="-D",
  13. donotify=True)
  14. @synchronized
  15. def stop():
  16. stopService(pidfile=PIDFILE,
  17. donotify=True)
  18. @synchronized
  19. def reload():
  20. stopService(command=DAEMON,
  21. signal=signal.SIGHUP)
  22. def status():
  23. return isServiceRunning(pidfile=PIDFILE)