repo.or.cz
/
aur-mirror.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
updated on Wed Jan 11 00:07:16 UTC 2012
[aur-mirror.git]
/
varnish
/
varnish.init
blob
b90ebf597c7399dbd0c269ddf5a8ae4b10e5515f
1
#!/bin/bash
2
3
# general config
4
.
/
etc
/
rc.conf
5
.
/
etc
/
rc.d
/
functions
6
7
.
/
etc
/
varnish.conf
8
9
PID
=
`pidof %PPID /usr/sbin/varnishd`
10
11
case
"
$1
"
in
12
start
)
13
stat_busy
"Starting Varnish Reverse Proxy"
14
/
usr
/
sbin
/
varnishd
$OPTS
15
if
[
$?
-gt
0
];
then
16
stat_fail
17
else
18
add_daemon varnish
19
stat_done
20
fi
21
;;
22
stop
)
23
stat_busy
"Stopping Varnish Reverse Proxy"
24
kill
$PID
&> /
dev
/
null
25
if
[
$?
-gt
0
];
then
26
stat_fail
27
else
28
rm_daemon varnish
29
stat_done
30
fi
31
;;
32
restart
)
33
$0
stop
34
sleep
1
35
$0
start
36
;;
37
*)
38
echo
"usage:
$0
{start|stop|restart}"
39
;;
40
esac
41
exit
0