#!/bin/sh
#
# $OpenBSD: amd,v 1.3 2011/07/16 09:33:29 sthen Exp $

daemon="/usr/sbin/amd"

. /etc/rc.d/rc.subr

rc_reload=NO
rc_restart=NO
rc_stop=NO

rc_pre() {
	[ -e ${amd_master} ] || return 1
	daemon_flags=$(cat ${amd_master})
}

rc_start() {
	${rcexec} "cd /etc/amd; ${daemon} ${daemon_flags}"
}

rc_cmd $1
