summaryrefslogtreecommitdiff
blob: 82288ebf19c3999834496943f0edb3286148048a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/sbin/openrc-run
# Copyright 2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

depend() {
	 need net
}

start() {
	local bootptab=${bootptab_file:-/etc/bootptab}

	if ! [ -f "${bootptab}" ]; then
		eerror "Unable to find the bootptab file: ${bootptab}"
		eend 1
		return 1
	fi

	ebegin "Starting BOOTP server"
	start-stop-daemon --start --exec /usr/libexec/bootpd -- ${bootpd_opts} ${bootptab}
	eend $?
}

stop() {
	ebegin "Stopping BOOTP server"
	start-stop-daemon --stop --exec /usr/libexec/bootpd
	eend $?
}