Skip to content

Commit d4b3c40

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "Fix Apparmor libvirt profile removal" into stable/wallaby
2 parents d95eb6a + 9b3b2fd commit d4b3c40

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

ansible/roles/baremetal/tasks/post-install.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,11 @@
201201
when: ansible_facts.distribution == "Ubuntu"
202202

203203
- name: Remove apparmor profile for libvirt
204-
command: apparmor_parser -R /etc/apparmor.d/usr.sbin.libvirtd
204+
shell: |
205+
apparmor_parser -v -R /etc/apparmor.d/usr.sbin.libvirtd && \
206+
ln -vsf /etc/apparmor.d/usr.sbin.libvirtd /etc/apparmor.d/disable
207+
args:
208+
executable: /bin/bash
205209
become: True
206210
when:
207211
- ansible_facts.distribution == "Ubuntu"
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
fixes:
3+
- |
4+
Fixes the baremetal role to avoid an error "Unable to remove "libvirtd".
5+
Now the symlink /etc/apparmor.d/disable/usr.sbin.libvirtd is created by
6+
the role.
7+
`LP#1960302 <https://bugs.launchpad.net/kolla-ansible/+bug/1960302>`__

0 commit comments

Comments
 (0)