Catch up with renaming of macros IRQn -> ICU_IRQn in i386/icu/icu.h,1.7
[dragonfly.git] / etc / rc.d / yppasswdd
blobb522cad933930e8d74a198ddb50f2c2c45abe69f
1 #!/bin/sh
3 # $NetBSD: yppasswdd,v 1.6 2002/03/22 04:34:01 thorpej Exp $
4 # $FreeBSD: src/etc/rc.d/yppasswdd,v 1.7 2003/07/09 03:21:03 mtm Exp $
5 # $DragonFly: src/etc/rc.d/yppasswdd,v 1.3 2004/01/27 00:55:43 rob Exp $
8 # PROVIDE: yppasswdd
9 # REQUIRE: ypserv ypbind
10 # BEFORE: LOGIN
11 # KEYWORD: DragonFly
13 . /etc/rc.subr
15 name="yppasswdd"
16 command="/usr/sbin/rpc.${name}"
17 start_precmd="yppasswdd_precmd"
19 load_rc_config $name
20 rcvar="nis_yppasswdd_enable"
21 command_args="${nis_yppasswdd_flags}"
23 yppasswdd_precmd()
25 if ! checkyesno rpcbind_enable && \
26 ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1
27 then
28 force_depend rpcbind || return 1
30 if ! checkyesno nis_server_enable && \
31 ! /etc/rc.d/ypserv forcestatus 1>/dev/null 2>&1
32 then
33 force_depend ypserv || return 1
35 _domain=`domainname`
36 if [ -z "$_domain" ]; then
37 warn "NIS domainname(1) is not set."
38 return 1
42 run_rc_command "$1"