Bug 1959328 - nesting.conf includes apparmor profile
Summary: nesting.conf includes apparmor profile
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: lxc
Version: 34
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Thomas Moschny
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-05-11 09:48 UTC by Andreas Vögele
Modified: 2021-09-27 01:24 UTC (History)
5 users (show)

Fixed In Version: lxc-4.0.10-1.fc35 lxc-4.0.10-1.fc34 lxc-4.0.10-1.fc33
Clone Of:
Environment:
Last Closed: 2021-09-24 20:28:36 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Andreas Vögele 2021-05-11 09:48:18 UTC
Description of problem:

lxc is built without AppArmor support but /usr/share/lxc/config/nesting.conf contains the below line. Containers that include this file don't start.

lxc.apparmor.profile = lxc-container-default-with-nesting

Version-Release number of selected component (if applicable):

lxc-templates-4.0.8-1.fc34

How reproducible:

Create and start a container with nesting enabled.

Steps to Reproduce:
1. Become root.
2. lxc-create -n mycontainer -t download -- -d fedora -r 34 -a amd64
3. sed -i '\|^#lxc.include = /usr/share/lxc/config/nesting.conf| s/^#//' /var/lib/lxc/mycontainer/config
4. lxc-start -n mycontainer -F

Actual results:

lxc-start: mycontainer: confile.c: set_config_apparmor_profile: 1463 Invalid argument - Built without AppArmor support
lxc-start: mycontainer: parse.c: lxc_file_for_each_line_mmap: 131 Failed to parse config file "/usr/share/lxc/config/nesting.conf" at line "lxc.apparmor.profile = lxc-container-default-with-nesting"

Expected results:

The container starts up.

Additional info:

Nesting works if the lxc.apparmor.profile line is commented out in /usr/share/lxc/config/nesting.conf.

Comment 1 Thomas Moschny 2021-05-11 21:08:02 UTC
We could patch nesting.conf. On the other hand I think it would be nice if LXC simply ignored that config, hence I opened https://github.com/lxc/lxc/issues/3839.

Comment 2 Fedora Update System 2021-09-18 15:33:15 UTC
FEDORA-2021-f97726e894 has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2021-f97726e894

Comment 3 Fedora Update System 2021-09-18 15:33:15 UTC
FEDORA-2021-f7e9ea3ba9 has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2021-f7e9ea3ba9

Comment 4 Fedora Update System 2021-09-18 15:33:18 UTC
FEDORA-2021-56e6155a0a has been submitted as an update to Fedora 35. https://bodhi.fedoraproject.org/updates/FEDORA-2021-56e6155a0a

Comment 5 Fedora Update System 2021-09-19 01:49:17 UTC
FEDORA-2021-56e6155a0a has been pushed to the Fedora 35 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-56e6155a0a`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-56e6155a0a

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 6 Fedora Update System 2021-09-19 05:42:30 UTC
FEDORA-2021-f7e9ea3ba9 has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-f7e9ea3ba9`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-f7e9ea3ba9

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 7 Fedora Update System 2021-09-19 05:50:01 UTC
FEDORA-2021-f97726e894 has been pushed to the Fedora 33 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-f97726e894`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-f97726e894

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 8 Fedora Update System 2021-09-24 20:28:36 UTC
FEDORA-2021-56e6155a0a has been pushed to the Fedora 35 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 9 Fedora Update System 2021-09-27 01:22:37 UTC
FEDORA-2021-f7e9ea3ba9 has been pushed to the Fedora 34 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 10 Fedora Update System 2021-09-27 01:24:58 UTC
FEDORA-2021-f97726e894 has been pushed to the Fedora 33 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.