bopm.init.d 450 B

1234567891011121314151617181920212223
  1. #!/sbin/openrc-run
  2. # Copyright 1999-2004 Gentoo Foundation
  3. # Distributed under the terms of the GNU General Public License v2
  4. opts="depend start stop"
  5. depend() {
  6. need net
  7. }
  8. start() {
  9. ebegin "Starting Blitzed Open Proxy Monitor"
  10. start-stop-daemon --start --quiet --chuid ${BOPM_UID} --exec /usr/bin/bopm
  11. eend $?
  12. }
  13. stop() {
  14. ebegin "Stopping Blitzed Open Proxy Monitor"
  15. kill $(</var/run/bopm/bopm.pid)
  16. eend $?
  17. rm -f /var/run/bopm/bopm.pid
  18. }