xref: /dflybsd-src/etc/rc.d/keyserv (revision e54c8dc8ef199e733518bad6fde7888f8bca3c8e)
19c600e7dSMatthew Dillon#!/bin/sh
29c600e7dSMatthew Dillon#
39c600e7dSMatthew Dillon# $FreeBSD: src/etc/rc.d/keyserv,v 1.2 2002/08/14 05:44:32 gordon Exp $
49c600e7dSMatthew Dillon#
59c600e7dSMatthew Dillon
69c600e7dSMatthew Dillon# Start keyserv if we are running Secure RPC
79c600e7dSMatthew Dillon#
89c600e7dSMatthew Dillon
99c600e7dSMatthew Dillon# PROVIDE: keyserv
109c600e7dSMatthew Dillon# REQUIRE: ypbind
119c600e7dSMatthew Dillon# BEFORE: DAEMON
129c600e7dSMatthew Dillon
139c600e7dSMatthew Dillon. /etc/rc.subr
149c600e7dSMatthew Dillon
159c600e7dSMatthew Dillonname="keyserv"
169c600e7dSMatthew Dillonrcvar=`set_rcvar`
179c600e7dSMatthew Dilloncommand="/usr/sbin/${name}"
189c600e7dSMatthew Dillonstart_precmd="keyserv_prestart"
199c600e7dSMatthew Dillon
209c600e7dSMatthew Dillonkeyserv_prestart()
219c600e7dSMatthew Dillon{
229c600e7dSMatthew Dillon	if ! checkyesno rpcbind_enable  && \
23*e54c8dc8SAaron LI	   ! /etc/rc.d/rpcbind forcestatus >/dev/null 2>&1
249c600e7dSMatthew Dillon	then
259c600e7dSMatthew Dillon		force_depend rpcbind || return 1
269c600e7dSMatthew Dillon	fi
279c600e7dSMatthew Dillon
289c600e7dSMatthew Dillon	return 0
299c600e7dSMatthew Dillon}
309c600e7dSMatthew Dillon
319c600e7dSMatthew Dillonload_rc_config $name
329c600e7dSMatthew Dillonrun_rc_command "$1"
33