apparmor: load profiles in parallel

This commit is contained in:
Andrea Brancaleoni 2021-02-14 21:39:38 +00:00 committed by Andrea Brancaleoni
parent 934f2ec7b7
commit 52ce6649fe
2 changed files with 2 additions and 10 deletions

View File

@ -1,7 +1,7 @@
# Template file for 'apparmor'
pkgname=apparmor
version=3.0.1
revision=2
revision=3
wrksrc="${pkgname}-v${version}"
build_wrksrc=libraries/libapparmor
build_style=gnu-configure

View File

@ -18,15 +18,7 @@ if [ -n "$APPARMOR" ]; then
[ "$APPARMOR" = "complain" ] && AACOMPLAIN="-C"
if [ -d /etc/apparmor.d -a -x /usr/bin/apparmor_parser ]; then
for profile in /etc/apparmor.d/*; do
case "$profile" in
*.new-*_*) continue ;;
esac
if [ -f "$profile" ]; then
printf '* Load profile %s: %s\n' "($APPARMOR)" "$profile"
apparmor_parser -a $AACOMPLAIN "$profile"
fi
done
apparmor_parser -a $AACOMPLAIN $(find /etc/apparmor.d -maxdepth 1 -type f ! -name '*.new-*_*')
else
printf '! AppArmor installation problem - ensure you have installed apparmor package\n'
fi