0001-Added-support-for-rcreload.patch

git patch - zcrownover, 07/17/2014 05:14 AM

Download (2.94 KB)

View differences:

sbin/rcrun/Makefile
1
# $DragonFly: src/sbin/rcrun/Makefile,v 1.3 2007/10/13 23:51:32 swildner Exp $
2

  
3 1
SCRIPTS=rcrun.sh
4 2
SYMLINKS= \
5 3
	rcrun ${BINDIR}/rcstart \
6 4
	rcrun ${BINDIR}/rcstop \
7 5
	rcrun ${BINDIR}/rcrestart \
6
	rcrun ${BINDIR}/rcreload \
8 7
	rcrun ${BINDIR}/rcvar \
9 8
	rcrun ${BINDIR}/rclist \
10 9
	rcrun ${BINDIR}/rcforce \
......
21 20
	rcrun.8 rcone.8 \
22 21
	rcrun.8 rclist.8 \
23 22
	rcrun.8 rcrestart.8 \
23
	rcrun.8 rcreload.8 \
24 24
	rcrun.8 rcstart.8 \
25 25
	rcrun.8 rcstop.8 \
26 26
	rcrun.8 rcvar.8
sbin/rcrun/rcrun.8
28 28
.\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29 29
.\" SUCH DAMAGE.
30 30
.\"
31
.Dd October 13, 2007
31
.Dd July 16, 2014
32 32
.Dt RCRUN 8
33 33
.Os
34 34
.Sh NAME
......
39 39
.Nm rcone ,
40 40
.Nm rcstop ,
41 41
.Nm rcrestart ,
42
.Nm rcreload ,
42 43
.Nm rcvar ,
43 44
.Nm rcdisable ,
44 45
.Nm rcenable ,
......
59 60
.Ar script ...
60 61
.Nm rcrestart
61 62
.Ar script ...
63
.Nm rcreload
64
.Ar script ...
62 65
.Nm rcvar
63 66
.Ar script ...
64 67
.Nm rcdisable
......
81 84
.Cm onestart ,
82 85
.Cm stop ,
83 86
.Cm restart ,
87
.Cm reload ,
84 88
and
85 89
.Cm rcvar
86 90
commands are just passed to the scripts.
......
121 125
.Nm rcone ,
122 126
.Nm rcstop ,
123 127
.Nm rcrestart ,
128
.Nm rcreload ,
124 129
.Nm rcvar ,
125 130
.Nm rcdisable ,
126 131
.Nm rcenable
sbin/rcrun/rcrun.sh
128 128
rcrestart)
129 129
    arg=restart
130 130
    ;;
131
rcreload)
132
    arg=reload
133
    ;;
131 134
rcvar)
132 135
    arg=rcvar
133 136
    ;;
......
193 196
	    fi
194 197
	done
195 198
	;;
199
reload)
200
	for tgt in $@; do
201
	    buildrclist $tgt
202
	    dep=`echo "$rclist" | tail -1`
203
	    if [ X$dep = X ]; then
204
		echo "Unable to find keyword $tgt"
205
	    else
206
		(sh $dep reload)
207
	    fi
208
	done
209
	;;
196 210
disable|enable)
197 211
	if [ "$arg" = "enable" ]; then
198 212
	    mode=YES
......
249 263
*)
250 264
	echo "usage: rcrun action rcscript1 ..."
251 265
	echo "  where 'action' is one of:"
252
	echo "    start|stop|restart|rcvar|list|forcestart|faststart|onestart"
253
	echo "    disable|enable"
266
	echo "    start|stop|restart|reload|rcvar|list|forcestart|faststart"
267
	echo "    onestart|disable|enable"
254 268
	;;
255 269
esac
256
-