Add option to fail if ceph-ansible is not installed
If someone is deploying Ceph then they need ceph-ansible. The warning might be overlooked and the user may end up with a message about a missing file. If Ceph is being deployed then we want to make the validation fail the deployment if ceph-ansible is not installed so that the user has a better error message to follow in order to debug. Also, update warning to refer to the ceph-ansible package. Change-Id: Ic099c61c74abf6da24a2cce899c944e3bf8ce26b
This commit is contained in:
parent
b8aa827047
commit
bf206aa97a
|
@ -7,6 +7,7 @@
|
|||
Prints a message if ceph-ansible isn't installed
|
||||
groups:
|
||||
- pre-deployment
|
||||
fail_without_ceph_ansible: false
|
||||
tasks:
|
||||
- include_role:
|
||||
name: ceph
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
---
|
||||
fail_without_ceph_ansible: false
|
|
@ -9,6 +9,14 @@
|
|||
|
||||
- name: Warn about missing ceph-ansible
|
||||
warn:
|
||||
msg: If planning to use Ceph, it is necessary to install the ceph-ansible on the undercloud
|
||||
msg: If planning to use Ceph, it is necessary to install the ceph-ansible package on the undercloud
|
||||
when:
|
||||
- ceph_ansible_installed.stdout.find('is not installed') != -1
|
||||
- not fail_without_ceph_ansible|default(false)|bool
|
||||
|
||||
- name: Fail if ceph-ansible is missing
|
||||
fail:
|
||||
msg: If planning to use Ceph, it is necessary to install the ceph-ansible package on the undercloud
|
||||
when:
|
||||
- ceph_ansible_installed.stdout.find('is not installed') != -1
|
||||
- fail_without_ceph_ansible|default(false)|bool
|
||||
|
|
Loading…
Reference in New Issue