#!/bin/sh
#
# PROVIDE: iperf
# BEFORE: DAEMON
# KEYWORD: shutdown
#
# Add the following line to /etc/rc.conf to enable iperf in server mode:
#
# iperf_enable="YES"
#
. /etc/rc.subr

name=iperf
rcvar=`set_rcvar`

command=/usr/local/bin/iperf
command_args="-s -D"

load_rc_config ${name}

iperf_enable=${iperf_enable-"NO"}

####
# iperf does not generate a pid file
# iperf_pidfile=${iperf_pidfile-"/var/run/.pid"}
# pidfile="${iperf_pidfile}"

run_rc_command "$1"

