Deleted Added
full compact
yppasswdd (136224) yppasswdd (165664)
1#!/bin/sh
2#
3# $NetBSD: yppasswdd,v 1.6 2002/03/22 04:34:01 thorpej Exp $
1#!/bin/sh
2#
3# $NetBSD: yppasswdd,v 1.6 2002/03/22 04:34:01 thorpej Exp $
4# $FreeBSD: head/etc/rc.d/yppasswdd 136224 2004-10-07 13:55:26Z mtm $
4# $FreeBSD: head/etc/rc.d/yppasswdd 165664 2006-12-30 22:53:20Z yar $
5#
6
7# PROVIDE: yppasswdd
8# REQUIRE: ypserv ypbind
9# BEFORE: LOGIN
10
11. /etc/rc.subr
12
13name="yppasswdd"
14command="/usr/sbin/rpc.${name}"
15start_precmd="yppasswdd_precmd"
16
17load_rc_config $name
18rcvar="nis_yppasswdd_enable"
19command_args="${nis_yppasswdd_flags}"
20
21yppasswdd_precmd()
22{
5#
6
7# PROVIDE: yppasswdd
8# REQUIRE: ypserv ypbind
9# BEFORE: LOGIN
10
11. /etc/rc.subr
12
13name="yppasswdd"
14command="/usr/sbin/rpc.${name}"
15start_precmd="yppasswdd_precmd"
16
17load_rc_config $name
18rcvar="nis_yppasswdd_enable"
19command_args="${nis_yppasswdd_flags}"
20
21yppasswdd_precmd()
22{
23 local _domain
24
23 if ! checkyesno rpcbind_enable && \
24 ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1
25 then
26 force_depend rpcbind || return 1
27 fi
28 if ! checkyesno nis_server_enable && \
29 ! /etc/rc.d/ypserv forcestatus 1>/dev/null 2>&1
30 then
31 force_depend ypserv || return 1
32 fi
33 _domain=`domainname`
34 if [ -z "$_domain" ]; then
35 warn "NIS domainname(1) is not set."
36 return 1
37 fi
38}
39
40run_rc_command "$1"
25 if ! checkyesno rpcbind_enable && \
26 ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1
27 then
28 force_depend rpcbind || return 1
29 fi
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
34 fi
35 _domain=`domainname`
36 if [ -z "$_domain" ]; then
37 warn "NIS domainname(1) is not set."
38 return 1
39 fi
40}
41
42run_rc_command "$1"