summaryrefslogtreecommitdiff
blob: a649e7c8b206e56d6f7717d630402cec0182ef0c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/sbin/runscript
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-proxy/c-icap/files/c-icap.init.2,v 1.1 2011/10/21 23:56:20 flameeyes Exp $

pidfile=$(awk '$1 == "PidFile" { print $2 }' /etc/c-icap/c-icap.conf)

command="/usr/libexec/c-icap"
command_arguments="${EXTRA_OPTS}"

depend() {
    need localmount net
}

start_pre() {
	cmdsocket=$(awk '$1 == "CommandsSocket" { print $2 }' /etc/c-icap/c-icap.conf)

	checkpath -d "$(dirname "${cmdsocket}")" "$(dirname "${pidfile}")"
}