Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from madaidan/patch-1
Fix AppArmor when not in live mode
- Loading branch information
Showing
3 changed files
with
19 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[Unit] | ||
Description=Fix AppArmor for live mode | ||
|
||
[Service] | ||
Type=oneshot | ||
ExecStart=/usr/lib/live-mode-apparmor | ||
|
||
[Install] | ||
WantedBy=multi-user.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/bin/bash | ||
|
||
## AppArmor profiles in live mode need the following line to work | ||
## but because of a bug in AppArmor, this breaks reloading profiles | ||
## so it is only enabled in live mode. | ||
|
||
if grep "boot=live" /proc/cmdline; then | ||
sed -i 's/# @{HOMEDIRS}+=\/rw\/home/@{HOMEDIRS}+=\/rw\/home/' /etc/apparmor.d/tunables/home.d/live-mode | ||
fi |