provisioning-libvirt: add tip about AppArmor#412
Conversation
|
|
||
| TIP: If running on a host with SELinux enabled (use the `sestatus` command to check SELinux status), make sure your OS image and Ignition file are labeled as `svirt_home_t`. You can do this by placing them under `~/.local/share/libvirt/images/` or running `chcon -t svirt_home_t /path/to/file`. | ||
|
|
||
| TIP: If running on a host with AppArmor enabled, you may need to change the AppArmor profile for libvirt. Add `/absolute/path/to/ignition/file.ign rk,` to the `LIBVIRT_TEMPLATE` profile that can be found in `/etc/apparmor.d/libvirt/TEMPLATE.qemu`. |
There was a problem hiding this comment.
According to @travier in #64 (comment), who pointed to https://ubuntu.com/server/docs/security-apparmor, it seems like this should be adding a dropin in /etc/apparmor.d/local/ instead?
There was a problem hiding this comment.
I am a bit unsure about that because libvirt relies on dynamic profiles created from the /etc/apparmor.d/libvirt/TEMPLATE.qemu template and removed upon VM removal. Local overrides are supposed to override specific profiles from what I understood.
In either case, I'll try to test it and revert with the results.
There was a problem hiding this comment.
libvirt itself does not uses those profiles directly, it's AppArmor configuration logic. Local overrides are there to add to distribution provided profiles, which in the case of AppArmor are still stored in /etc unfortunately.
Supersedes #64