From: | "Doug Goldstein (cardoe)" <cardoe@g.o> |
---|---|
To: | gentoo-commits@l.g.o |
Subject: | [gentoo-commits] gentoo-x86 commit in sys-auth/nss-ldapd/files: nslcd.rc |
Date: | Fri, 05 Dec 2008 21:12:53 |
Message-Id: | E1L8hym-0007Ab-2h@stork.gentoo.org |
1 | cardoe 08/12/05 21:12:52 |
2 | |
3 | Modified: nslcd.rc |
4 | Log: |
5 | merge in improvements from Sunrise Overlay by Heath Caldwell <hncaldwell@g.o> |
6 | (Portage version: 2.1.6_rc2/cvs/Linux 2.6.27-gentoo-r2 x86_64) |
7 | |
8 | Revision Changes Path |
9 | 1.2 sys-auth/nss-ldapd/files/nslcd.rc |
10 | |
11 | file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-auth/nss-ldapd/files/nslcd.rc?rev=1.2&view=markup |
12 | plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-auth/nss-ldapd/files/nslcd.rc?rev=1.2&content-type=text/plain |
13 | diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-auth/nss-ldapd/files/nslcd.rc?r1=1.1&r2=1.2 |
14 | |
15 | Index: nslcd.rc |
16 | =================================================================== |
17 | RCS file: /var/cvsroot/gentoo-x86/sys-auth/nss-ldapd/files/nslcd.rc,v |
18 | retrieving revision 1.1 |
19 | retrieving revision 1.2 |
20 | diff -u -r1.1 -r1.2 |
21 | --- nslcd.rc 4 Dec 2008 22:17:14 -0000 1.1 |
22 | +++ nslcd.rc 5 Dec 2008 21:12:52 -0000 1.2 |
23 | @@ -1,17 +1,35 @@ |
24 | #!/sbin/runscript |
25 | # Copyright 1999-2008 Gentoo Foundation |
26 | # Distributed under the terms of the GNU General Public License v2 |
27 | -# $Header: /var/cvsroot/gentoo-x86/sys-auth/nss-ldapd/files/nslcd.rc,v 1.1 2008/12/04 22:17:14 cardoe Exp $ |
28 | +# $Header: /var/cvsroot/gentoo-x86/sys-auth/nss-ldapd/files/nslcd.rc,v 1.2 2008/12/05 21:12:52 cardoe Exp $ |
29 | + |
30 | +opts="checkconfig" |
31 | |
32 | depend() { |
33 | need net |
34 | + use dns logger |
35 | +} |
36 | + |
37 | +checkconfig() { |
38 | + if [ ! -f /etc/nss-ldapd.conf ] ; then |
39 | + eerror "Please create /etc/nss-ldapd.conf" |
40 | + eerror "Example config: /usr/share/nss-ldapd/nss-ldapd.conf" |
41 | + return 1 |
42 | + fi |
43 | + return 0 |
44 | } |
45 | |
46 | start() { |
47 | + checkconfig || return $? |
48 | + |
49 | + ebegin "Starting nslcd" |
50 | start-stop-daemon --start --pidfile /var/run/nslcd/nslcd.pid \ |
51 | --exec /usr/sbin/nslcd |
52 | + eend $? "Failed to start nslcd" |
53 | } |
54 | |
55 | stop() { |
56 | + ebegin "Stopping nslcd" |
57 | start-stop-daemon --stop --pidfile /var/run/nslcd/nslcd.pid |
58 | + eend $? "Failed to stop nslcd" |
59 | } |