#!/bin/sh
#
# $FreeBSD: ports/net-mgmt/ipcad/files/ipcad.in,v 1.5 2012/11/17 06:00:33 svnexp Exp $
#
# PROVIDE: ipcad
# REQUIRE: DAEMON
#
# Add the following lines to /etc/rc.conf to run ipcad:
#
# ipcad_enable (bool):		Set it to "YES" to enable ipcad.
#				Default is "NO".
# ipcad_conf (file):		Set local of config file.
#				Default is "/usr/local/etc/ipcad.conf".
# ipcad_flags="<set as needed>"

. /etc/rc.subr

name="ipcad"
rcvar=ipcad_enable

load_rc_config ${name}

: ${ipcad_enable="NO"}
: ${ipcad_conf="/usr/local/etc/ipcad.conf"}

required_files="${ipcad_conf}"
command=/usr/local/bin/ipcad
command_args="-rds -c ${ipcad_conf}"

run_rc_command "$1"
