ypbind revision 124622
178344Sobrien#!/bin/sh 278344Sobrien# 398184Sgordon# $NetBSD: ypbind,v 1.5 2002/03/22 04:34:01 thorpej Exp $ 498184Sgordon# $FreeBSD: head/etc/rc.d/ypbind 124622 2004-01-17 10:59:43Z mtm $ 578344Sobrien# 678344Sobrien 778344Sobrien# PROVIDE: ypbind 878344Sobrien# REQUIRE: ypserv 998184Sgordon# BEFORE: DAEMON 10124616Smtm# KEYWORD: FreeBSD 1178344Sobrien 1278344Sobrien. /etc/rc.subr 1378344Sobrien 1478344Sobrienname="ypbind" 1578344Sobriencommand="/usr/sbin/${name}" 1678344Sobrienstart_precmd="ypbind_precmd" 1778344Sobrien 18109770Smtmload_rc_config $name 19124622Smtmrcvar="nis_client_enable" 20124622Smtmcommand_args="${nis_client_flags}" 2198184Sgordon 2278344Sobrienypbind_precmd() 2378344Sobrien{ 24124622Smtm if ! checkyesno rpcbind_enable && \ 25124622Smtm ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1 26124622Smtm then 27124622Smtm force_depend rpcbind || return 1 28124622Smtm fi 29106431Sfenner 3078344Sobrien _domain=`domainname` 3178344Sobrien if [ -z "$_domain" ]; then 32117346Smtm warn "NIS domainname(1) is not set." 3378344Sobrien return 1 3478344Sobrien fi 3578344Sobrien} 3678344Sobrien 3778344Sobrienrun_rc_command "$1" 38