diff options
Diffstat (limited to 'net/traff/files/traff.sh.in')
-rw-r--r-- | net/traff/files/traff.sh.in | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/net/traff/files/traff.sh.in b/net/traff/files/traff.sh.in new file mode 100644 index 000000000000..b37a8b173fc4 --- /dev/null +++ b/net/traff/files/traff.sh.in @@ -0,0 +1,39 @@ +#!/bin/sh +# +# +# PROVIDE: traff +# REQUIRE: DAEMON +# BEFORE: LOGIN +# KEYWORD: FreeBSD shutdown + +# +# Add the following lines to /etc/rc.conf to enable traff: +# +# traff_enable="YES" +# +# + +. %%RC_SUBR%% + +name=traff +rcvar=`set_rcvar` + + +command=%%PREFIX%%/sbin/traff +pidfile=/var/run/traff.pid +required_files=%%PREFIX%%/etc/traff.conf + +stop_postcmd=stop_postcmd + +stop_postcmd() +{ + rm -f $pidfile +} + +# set defaults + +traff_enable=${traff_enable:-"NO"} + +load_rc_config $name +run_rc_command "$1" + |