sysklogd: fix build on musl
[buildroot-gz.git] / package / c-icap / S96cicap
blob7b95f86009f9749d4b6a391bd04238ebef4dca1b
1 #!/bin/sh
3 # (Re)create directories
4 mkdir -p /var/run/c-icap
5 mkdir -p /var/log/c-icap
7 case "$1" in
8 start)
9 printf "Starting c-icap server: "
10 start-stop-daemon -S -q -b -m -p /var/run/c-icap.pid \
11 -x /usr/bin/c-icap -- -N
12 [ $? == 0 ] && echo "OK" || echo "FAIL"
14 stop)
15 printf "Stopping c-icap server: "
16 start-stop-daemon -K -q -p /var/run/c-icap.pid
17 [ $? = 0 ] && echo "OK" || echo "FAIL"
19 restart|reload)
20 $0 stop
21 sleep 1
22 $0 start
25 echo "Usage: /etc/init.d/S96cicap {start|stop|restart|reload}"
26 exit 1
27 esac