File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ " app-builder-lib " : patch
3
+ ---
4
+
5
+ fix: Only update AppArmor profile if not chroot'ed
Original file line number Diff line number Diff line change @@ -568,7 +568,10 @@ if test -d "/etc/apparmor.d"; then
568
568
if apparmor_parser --skip-kernel-load --debug "$APPARMOR_PROFILE_SOURCE" > /dev/null 2>&1; then
569
569
cp -f "$APPARMOR_PROFILE_SOURCE" "$APPARMOR_PROFILE_TARGET"
570
570
571
- if hash apparmor_parser 2>/dev/null; then
571
+ # Updating the current AppArmor profile is not possible and probably not meaningful in a chroot'ed environment.
572
+ # Use cases are for example environments where images for clients are maintained.
573
+ # There, AppArmor might correctly be installed, but live updating makes no sense.
574
+ if ! { [ - x ' /usr/bin/ischroot' ] && / usr / bin / ischroot ; } && hash apparmor_parser 2>/dev/null; then
572
575
# Extra flags taken from dh_apparmor:
573
576
# > By using '-W -T' we ensure that any abstraction updates are also pulled in.
574
577
# https://wiki.debian.org/AppArmor/Contribute/FirstTimeProfileImport
You can’t perform that action at this time.
0 commit comments