siproxd.rc8 464 B

12345678910111213141516171819202122
  1. #!/sbin/openrc-run
  2. # Copyright 1999-2016 Gentoo Foundation
  3. # Distributed under the terms of the GNU General Public License v2
  4. config_file="/etc/siproxd.conf"
  5. pidfile="/var/run/siproxd/siproxd.pid"
  6. command="/usr/sbin/siproxd"
  7. command_args="-p ${pidfile} -c ${config_file}"
  8. depend() {
  9. need net
  10. }
  11. start_pre() {
  12. if [ ! -f "${config_file}" ] ; then
  13. eerror "Please create ${config_file} first!"
  14. return 1
  15. fi
  16. checkpath -q -d ${pidfile%/*} -o siproxd:siproxd
  17. }