]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - etc/rc.d/ypbind
Add a missing ;.
[FreeBSD/FreeBSD.git] / etc / rc.d / ypbind
1 #!/bin/sh
2 #
3 # $FreeBSD$
4 #
5
6 # PROVIDE: ypbind
7 # REQUIRE: ypserv
8 # BEFORE:  DAEMON
9
10 . /etc/rc.subr
11
12 name="ypbind"
13 command="/usr/sbin/${name}"
14 start_precmd="ypbind_precmd"
15
16 load_rc_config $name
17 rcvar="nis_client_enable"
18 command_args="${nis_client_flags}"
19
20 ypbind_precmd()
21 {
22         local _domain
23
24         if ! checkyesno rpcbind_enable  && \
25             ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1
26         then
27                 force_depend rpcbind || return 1
28         fi
29
30         _domain=`domainname`
31         if [ -z "$_domain" ]; then
32                 warn "NIS domainname(1) is not set."
33                 return 1
34         fi
35 }
36
37 run_rc_command "$1"