Lines 2-8
Link Here
|
2 |
# Copyright (c) 2007-2008 Roy Marples <roy@marples.name> |
2 |
# Copyright (c) 2007-2008 Roy Marples <roy@marples.name> |
3 |
# All rights reserved. Released under the 2-clause BSD license. |
3 |
# All rights reserved. Released under the 2-clause BSD license. |
4 |
|
4 |
|
5 |
description="Executes user commands in /etc/conf.d/local" |
5 |
description="Executes user scripts in /etc/localstart.d and /etc/localstop.d" |
6 |
|
6 |
|
7 |
depend() |
7 |
depend() |
8 |
{ |
8 |
{ |
Lines 14-20
start()
Link Here
|
14 |
{ |
14 |
{ |
15 |
ebegin "Starting local" |
15 |
ebegin "Starting local" |
16 |
|
16 |
|
|
|
17 |
local sh |
18 |
for sh in @SYSCONFDIR@/local.d/*start.sh ; do |
19 |
[ -r "$sh" ] && . "$sh" |
20 |
done |
21 |
|
17 |
if type local_start >/dev/null 2>&1; then |
22 |
if type local_start >/dev/null 2>&1; then |
|
|
23 |
ewarn "@SYSCONFDIR@/conf.d/local should be removed." |
24 |
ewarn "Please move the code from the local_start function" |
25 |
ewarn "to scripts ending in start.sh in @SYSCONFDIR@/local.d" |
18 |
local_start |
26 |
local_start |
19 |
fi |
27 |
fi |
20 |
|
28 |
|
Lines 25-31
stop()
Link Here
|
25 |
{ |
33 |
{ |
26 |
ebegin "Stopping local" |
34 |
ebegin "Stopping local" |
27 |
|
35 |
|
|
|
36 |
local sh |
37 |
for sh in @SYSCONFDIR@/local.d/*stop.sh ; do |
38 |
[ -r "$sh" ] && . "$sh" |
39 |
done |
40 |
|
28 |
if type local_start >/dev/null 2>&1; then |
41 |
if type local_start >/dev/null 2>&1; then |
|
|
42 |
ewarn "@SYSCONFDIR@/conf.d/local should be removed." |
43 |
ewarn "Please move the code from the local_stop function" |
44 |
ewarn "to scripts ending in stop.sh in @SYSCONFDIR@/localstop.d" |
29 |
local_stop |
45 |
local_stop |
30 |
fi |
46 |
fi |
31 |
|
47 |
|