Permalink
Browse files
Add support for classic confinement
This patch adds support for classic confinement in snap-confine. The main idea is that whenever --classic command line option is given the mount namespace is not unshared. The application executes in the same mount namespace as all classic applications would. While not strictly related to the mount namespace, the devices cgroup is not used and PATH is not reset. On the snapd side the application will receive different apparmor and seccomp profiles. The apprmor profile is wide open and the seccomp profile uses the special "@unrestricted" command to essentially switch apparmor off entirely. NOTE: Using classic confinement is incompatible with nvidia driver sharing as we cannot bind mount anything into /var/lib/snapd/lib/gl but at the same time the application can just look at /usr/lib/nvidia for that. Signed-off-by: Zygmunt Krynicki <zygmunt.krynicki@canonical.com>
- Loading branch information...
LGTM but please add a code comment. Ie:
Feel free to wordsmith that as desired. This should also be documented in README.md.