Merge pull request #1644 from fullerdj/wip-djf-check-devices

osd: validate devices variable input
pull/1664/head
Sébastien Han 2017-07-07 15:48:39 +02:00 committed by GitHub
commit 0f1f4388da
1 changed files with 21 additions and 0 deletions

View File

@ -55,6 +55,15 @@
- not osd_auto_discovery
- devices|length == 0
- name: make sure the devices variable is a list
fail:
msg: "devices: must be a list, not a string, i.e. [ \"/dev/sda\" ]"
when:
- osd_group_name is defined
- osd_group_name in group_names
- not osd_auto_discovery
- devices is string
- name: verify journal devices have been provided
fail:
msg: "please provide devices and raw journal devices to your osd scenario"
@ -66,6 +75,18 @@
- raw_journal_devices|length == 0
or devices|length == 0
- name: make sure the raw_journal_devices variable is a list
fail:
msg: "raw_journal_devices: must be a list, not a string, i.e. [ \"/dev/sda\" ]"
when:
- osd_group_name is defined
- osd_group_name in group_names
- not containerized_deployment
- raw_multi_journal
- raw_journal_devices is string
- raw_journal_devices|length == 0
or devices|length == 0
- name: check if bluestore is supported by the selected ceph version
fail:
msg: "bluestore is not supported by the selected Ceph version, use Luminous or above."