summaryrefslogtreecommitdiff
blob: efe9cc39a3af1f471b9ad6e690a8ba7bd4979ff6 (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
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/sbin/runscript
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

APPARMOR_FUNCTIONS=/lib/apparmor/rc.apparmor.functions
APPARMOR_HELPERS=/lib/apparmor/rc.helper.functions
if [ -f "${APPARMOR_HELPERS}" -a -f "${APPARMOR_FUNCTIONS}" ]; then
	source ${APPARMOR_HELPERS}
	source ${APPARMOR_FUNCTIONS}
else
        eend 1 "Unable to find AppArmor initscript functions"
fi

depend() {
	need apparmor
	use logger dns
}

start() {
	ebegin "Starting aaeventd (AppArmor Event Daemon)"

	if [ "${APPARMOR_ENABLE_AAEVENTD}" = "no" ]; then
		eend 1 "   aaeventd disabled in ${APPARMOR_CONF}."
	fi

	start_sd_event
	eend $waserror
}

stop() {
	ebegin "Stopping aaeventd (AppArmor Event Daemon)"
	stop_sd_event
	eend $waserror
}

restart() {
	srv_stop
	srv_start
}