Skip to content

Commit

Permalink
wrappers/remote-viewer: workaround Apparmor unpriv userns mediation
Browse files Browse the repository at this point in the history
Signed-off-by: Simon Deziel <[email protected]>
  • Loading branch information
simondeziel authored and tomponline committed Oct 6, 2023
1 parent e17a59a commit 70ad2cd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion snapcraft/wrappers/remote-viewer
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ run_cmd() {
}

USERNS=1
[ -e /proc/sys/kernel/unprivileged_userns_clone ] && grep -q 0 /proc/sys/kernel/unprivileged_userns_clone && USERNS=0
[ -e /proc/sys/kernel/unprivileged_userns_clone ] && grep -qxF 0 /proc/sys/kernel/unprivileged_userns_clone && USERNS=0
[ -e /proc/sys/kernel/apparmor_restrict_unprivileged_userns ] && grep -qxF 1 /proc/sys/kernel/apparmor_restrict_unprivileged_userns && USERNS=0

find_and_spawn() {
for path in / /usr/ /usr/local/; do
Expand Down

0 comments on commit 70ad2cd

Please sign in to comment.