summaryrefslogtreecommitdiff
path: root/etc/rc.d/vmd
blob: 4f8e8a7ae73f120064698ae57d8e300e7de26cf6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/ksh
#
# $OpenBSD: vmd,v 1.10 2019/01/21 01:41:16 claudio Exp $

daemon="/usr/sbin/vmd"

. /etc/rc.d/rc.subr

# Child will not return a config parsing error to the parent.
rc_pre() {
	# use rcexec here since daemon_flags may contain arguments with spaces
	${rcexec} "${daemon} -n ${daemon_flags}"
}

rc_stop() {
	_rc_do vmctl stop -a -w
	pkill -T "${daemon_rtable}" -xf "${pexp}"
}

rc_cmd $1