aboutsummaryrefslogtreecommitdiffstats
path: root/main/lsyncd/lsyncd.initd
blob: 103a8b42be8d26fe796461f3b4c408f653179e77 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/sbin/runscript

command=/usr/bin/lsyncd
pidfile=/var/run/lsyncd/${SVCNAME}.pid
conf=/etc/lsyncd/${SVCNAME}.lua

: ${exec_user:=root}
: ${exec_group:=root}

start_stop_daemon_args="--user $exec_user --group $exec_group --chdir /etc/lsyncd"

depend() {
	need net
	after firewall
}

start_pre() {
	checkpath --directory ${pidfile%/*} --owner ${exec_user}:${exec_group}
	command_args="$conf -pidfile $pidfile $command_args"
}