aboutsummaryrefslogtreecommitdiffstats
path: root/community/keepalived/keepalived.initd
blob: 760c360c895398ec4337b6a89c60cef45b6db2d8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/sbin/openrc-run
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

extra_commands="reload"

command="/usr/sbin/keepalived"
command_args="${KEEPALIVED_OPTS}"
pidfile="/run/keepalived.pid"
required_files="/etc/keepalived/keepalived.conf"

depend() {
	use logger
	# The interfaces do not actually need to exist to start,
	# it handles them gracefully.
	use net
}

reload() {
	ebegin "Reloading keepalived.conf"
	start-stop-daemon --pidfile $pidfile --signal HUP
	eend $?
}