From: Andrew Schoen Date: Thu, 5 Apr 2018 14:12:32 +0000 (-0500) Subject: ceph_volume: objectstore should default to 'bluestore' X-Git-Tag: v3.1.0beta6~13 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=4a4fb1a4df73021f658415618244011f0cd1e780;p=ceph-ansible.git ceph_volume: objectstore should default to 'bluestore' Signed-off-by: Andrew Schoen --- diff --git a/library/ceph_volume.py b/library/ceph_volume.py index ef61a7d9b..e95c97949 100644 --- a/library/ceph_volume.py +++ b/library/ceph_volume.py @@ -31,6 +31,7 @@ options: - Required if action is 'create' required: false choices: ['bluestore', 'filestore'] + default: bluestore action: description: - The action to take. Either creating OSDs or zapping devices. @@ -141,7 +142,7 @@ def get_wal(wal, wal_vg): def create_osd(module): cluster = module.params['cluster'] - objectstore = module.params.get('objectstore') + objectstore = module.params['objectstore'] data = module.params['data'] data_vg = module.params.get('data_vg', None) journal = module.params.get('journal', None) @@ -153,9 +154,6 @@ def create_osd(module): crush_device_class = module.params.get('crush_device_class', None) dmcrypt = module.params['dmcrypt'] - if not objectstore: - module.fail_json(msg="The objectstore param is required if action is 'create'. Choices are 'bluestore' or 'filestore'.", changed=False) - cmd = [ 'ceph-volume', '--cluster', @@ -314,7 +312,7 @@ def zap_devices(module): def run_module(): module_args = dict( cluster=dict(type='str', required=False, default='ceph'), - objectstore=dict(type='str', required=False, choices=['bluestore', 'filestore']), + objectstore=dict(type='str', required=False, choices=['bluestore', 'filestore'], default='bluestore'), action=dict(type='str', required=False, choices=['create', 'zap'], default='create'), data=dict(type='str', required=True), data_vg=dict(type='str', required=False),