diff options
Diffstat (limited to 'meta-oe/recipes-support/openldap/openldap-2.4.39/initscript')
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/initscript | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.39/initscript b/meta-oe/recipes-support/openldap/openldap-2.4.39/initscript new file mode 100644 index 000000000..08d1067a7 --- /dev/null +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/initscript | |||
@@ -0,0 +1,35 @@ | |||
1 | #! /bin/sh | ||
2 | # | ||
3 | # This is an init script for openembedded | ||
4 | # Copy it to /etc/init.d/openldap and type | ||
5 | # > update-rc.d openldap defaults 60 | ||
6 | # | ||
7 | |||
8 | # Source function library. | ||
9 | . /etc/init.d/functions | ||
10 | |||
11 | slapd=/usr/sbin/slapd | ||
12 | test -x "$slapd" || exit 0 | ||
13 | |||
14 | |||
15 | case "$1" in | ||
16 | start) | ||
17 | echo -n "Starting OpenLDAP: " | ||
18 | start-stop-daemon --start --quiet --exec $slapd | ||
19 | echo "." | ||
20 | ;; | ||
21 | stop) | ||
22 | echo -n "Stopping OpenLDAP: " | ||
23 | start-stop-daemon --stop --quiet --pidfile /var/run/slapd.pid | ||
24 | echo "." | ||
25 | ;; | ||
26 | status) | ||
27 | status $slapd; | ||
28 | exit $? | ||
29 | ;; | ||
30 | *) | ||
31 | echo "Usage: /etc/init.d/openldap {start|stop|status}" | ||
32 | exit 1 | ||
33 | esac | ||
34 | |||
35 | exit 0 | ||