Ignore libvirt start if running chrooted

The use case is when running oooq from a
privileged container. For examle, running in
Centos container on the Ubuntu virthost.
Services can't be restarted in such a container
unless you run it as a VM (with init as pid 1).
So oooq can't pass the libvirt startup task and
proceed with undercloud deployment. This is
controlled by a new var 'chrooted'. Defaults to
False.

Partial-bug: #1676373
Change-Id: If221a6a8bda496862da6249c46c2bedd955b6eac
Signed-off-by: Bogdan Dobrelya <bdobreli@redhat.com>
This commit is contained in:
Bogdan Dobrelya 2017-03-17 14:29:08 +01:00
parent 6d3f07f262
commit a4e1ea67f6
2 changed files with 3 additions and 1 deletions

View File

@ -10,3 +10,5 @@ libvirt_packages:
# The name of the libvirt service.
libvirtd_service: libvirtd
# If running in chroot-like environments (containers)
chrooted: false

View File

@ -27,4 +27,4 @@
state: running
enabled: true
become: true
when: not chrooted|bool