Merge "Set lxc.autodev=0 for cinder_volumes in containers"
This commit is contained in:
commit
fa9ffcc31c
@ -190,6 +190,8 @@ cinder_backends_rbd_inuse: >
|
||||
endfor %}{{
|
||||
_var.rbd_inuse }}
|
||||
cinder_ceph_client: cinder
|
||||
# cinder_backend_lvm_inuse: True if current host has an lvm backend
|
||||
cinder_backend_lvm_inuse: '{{ (cinder_backends|default("")|to_json).find("cinder.volume.drivers.lvm.LVMVolumeDriver") != -1 }}'
|
||||
|
||||
|
||||
## OpenStack Openrc
|
||||
|
@ -50,11 +50,15 @@
|
||||
lxc_container:
|
||||
name: "{{ container_name }}"
|
||||
container_config:
|
||||
- "lxc.autodev=0"
|
||||
- "lxc.aa_profile=unconfined"
|
||||
- "lxc.cgroup.devices.allow=a *:* rmw"
|
||||
- "lxc.mount.entry = udev dev devtmpfs defaults 0 0"
|
||||
- "lxc.mount.entry=udev dev devtmpfs defaults 0 0"
|
||||
delegate_to: "{{ physical_host }}"
|
||||
when: (is_metal == false or is_metal == "False") and inventory_hostname in groups['cinder_volume']
|
||||
when: >
|
||||
(is_metal == false or is_metal == "False") and
|
||||
inventory_hostname in groups['cinder_volume'] and
|
||||
cinder_backend_lvm_inuse
|
||||
tags:
|
||||
- cinder-container-setup
|
||||
register: lxc_config
|
||||
|
@ -37,3 +37,4 @@
|
||||
- include: cinder_lvm_config.yml
|
||||
when: >
|
||||
inventory_hostname in groups['cinder_volume']
|
||||
and cinder_backend_lvm_inuse
|
||||
|
Loading…
Reference in New Issue
Block a user