#!/bin/sh # Start or stop apolicyd # $FreeBSD: head/mail/py-apolicy/files/apolicyd.in 340872 2014-01-24 00:14:07Z mat $ # PROVIDE: apolicyd # REQUIRE: TWISTD # KEYWORD: shutdown # Define these apolicyd_* variables in one of these files: # /etc/rc.conf # /etc/rc.conf.local # # DO NOT CHANGE THESE DEFAULT VALUES HERE . /etc/rc.subr name="apolicyd" rcvar=apolicyd_enable command="%%PREFIX%%/bin/twistd" pidfile="/var/run/apolicyd.pid" logfile="/var/log/apolicyd.log" load_rc_config $name : ${apolicyd_enable="NO"} command_args="--pidfile=${pidfile} -y %%PYTHON_SITELIBDIR%%/apolicy/server.py -q --logfile=${logfile} 2>&1 >/dev/null" procname="%%PYTHON_CMD%%" run_rc_command "$1"