]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
action: Use aa-teardown to disable apparmor
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Sat, 8 Jun 2024 10:16:31 +0000 (12:16 +0200)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Sat, 8 Jun 2024 10:32:32 +0000 (12:32 +0200)
systemctl stop apparmor doesn't seem to be sufficient, aa-teardown
on the other hand seems to do the trick.

action.yaml

index abbc6125252f3bf9dc6c77b839ba5fabed20d6c2..267e199db675d197854d615faec7c13423505e6b 100644 (file)
@@ -44,8 +44,9 @@ runs:
   - name: Disable and mask apparmor service
     shell: bash
     run: |
-        sudo systemctl disable --now apparmor
-        sudo systemctl mask apparmor
+        # This command fails with a non-zero error code even though it unloads the apparmor profiles.
+        # https://gitlab.com/apparmor/apparmor/-/issues/403
+        sudo aa-teardown || true
         sudo apt-get remove apparmor
 
   - name: Dependencies