mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2025-04-03 00:07:05 +00:00
Don't apply apparmor configuration when apparmor is disabled (eg. travis-ci)
This commit is contained in:
parent
c945d8fbb3
commit
1d789dbe53
@ -10,11 +10,11 @@ os: linux
|
||||
dist: bionic
|
||||
|
||||
before_install:
|
||||
- echo "Updating system"
|
||||
- sudo aa-status
|
||||
- sudo apt-get update
|
||||
|
||||
install:
|
||||
- sudo ./setup/start.sh
|
||||
- sudo ./setup/start.sh -v
|
||||
|
||||
script:
|
||||
- sudo ./tests/runner.sh
|
||||
|
@ -632,8 +632,10 @@ update_apparmor() {
|
||||
EOF
|
||||
chmod 0644 /etc/apparmor.d/local/usr.sbin.slapd
|
||||
|
||||
# Load settings into the kernel
|
||||
apparmor_parser -r /etc/apparmor.d/usr.sbin.slapd
|
||||
# Load settings into the kernel only if AppArmor is enabled
|
||||
if aa-status --enabled; then
|
||||
apparmor_parser -r /etc/apparmor.d/usr.sbin.slapd
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user