2014-03-04 02:08:51 +08:00
---
2018-03-15 06:46:23 +08:00
- name : include system_tuning.yml
2018-03-15 06:39:10 +08:00
include : system_tuning.yml
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2018-04-11 23:15:29 +08:00
- name : install dependencies
package :
name : parted
state : present
2017-09-15 06:48:53 +08:00
when :
- not containerized_deployment
2018-04-11 23:15:29 +08:00
- ansible_os_family != 'ClearLinux'
- name : include common.yml
include : common.yml
2016-08-17 05:49:30 +08:00
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2014-03-04 02:08:51 +08:00
2017-09-15 06:48:53 +08:00
- name : include ceph_disk_cli_options_facts.yml
include : ceph_disk_cli_options_facts.yml
2017-07-25 23:54:26 +08:00
2017-11-14 18:58:38 +08:00
- name : include build_devices.yml
include : build_devices.yml
2017-09-28 06:17:12 +08:00
2018-04-13 22:36:43 +08:00
- name : read information about the devices
parted :
device : "{{ item }}"
unit : MiB
2017-09-28 06:17:12 +08:00
register : parted_results
2018-04-13 22:36:43 +08:00
with_items : "{{ devices }}"
2017-07-25 23:54:26 +08:00
2017-11-18 00:32:23 +08:00
- name : include check_gpt.yml
include : check_gpt.yml
2018-05-16 17:58:31 +08:00
when :
- osd_scenario != 'lvm'
2017-11-18 00:32:23 +08:00
2017-09-15 06:48:53 +08:00
- name : include scenarios/collocated.yml
include : scenarios/collocated.yml
2016-04-01 18:57:58 +08:00
when :
2017-07-27 23:05:59 +08:00
- osd_scenario == 'collocated'
2016-08-17 05:49:30 +08:00
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2014-03-04 02:08:51 +08:00
2017-09-15 06:48:53 +08:00
- name : include scenarios/non-collocated.yml
include : scenarios/non-collocated.yml
2016-04-01 18:57:58 +08:00
when :
2017-09-28 06:17:12 +08:00
- not osd_auto_discovery
2017-07-27 23:05:59 +08:00
- osd_scenario == 'non-collocated'
2016-08-17 05:49:30 +08:00
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2016-07-19 23:53:21 +08:00
2017-09-15 06:48:53 +08:00
- name : include scenarios/lvm.yml
include : scenarios/lvm.yml
2017-07-19 23:05:42 +08:00
when :
2017-08-03 23:08:34 +08:00
- osd_scenario == 'lvm'
2017-07-19 23:05:42 +08:00
- not containerized_deployment
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2017-09-15 06:48:53 +08:00
- name : include activate_osds.yml
include : activate_osds.yml
2017-09-13 05:49:11 +08:00
when :
- not containerized_deployment
2018-05-16 17:58:31 +08:00
- osd_scenario != 'lvm'
2017-09-13 05:49:11 +08:00
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2017-09-15 06:48:53 +08:00
- name : include start_osds.yml
2017-07-26 05:48:13 +08:00
include : start_osds.yml
when :
- not containerized_deployment
2018-05-16 17:58:31 +08:00
- osd_scenario != 'lvm'
2017-07-26 05:48:13 +08:00
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2017-09-15 06:48:53 +08:00
- name : include docker/main.yml
include : docker/main.yml
when :
- containerized_deployment
2016-08-17 05:49:30 +08:00
# Hard code this so we will skip the entire file instead of individual tasks (Default isn't Consistent)
static : False
2018-05-22 22:41:40 +08:00
2018-06-01 21:11:21 +08:00
- name : set_fact openstack_keys_tmp - preserve backward compatibility after the introduction of the ceph_keys module
set_fact :
openstack_keys_tmp : "{{ openstack_keys_tmp|default([]) + [ { 'key': item.key, 'name': item.name, 'caps': { 'mon': item.mon_cap, 'osd': item.osd_cap|default(''), 'mds': item.mds_cap|default(''), 'mgr': item.mgr_cap|default('') } , 'mode': item.mode } ] }}"
with_items : "{{ openstack_keys }}"
when :
- item.get('mon_cap', None) # it's enough to assume we are running an old-fashionned syntax simply by checking the presence of mon_cap since every key needs this cap
- name : set_fact keys - override keys_tmp with keys
set_fact :
openstack_keys : "{{ openstack_keys_tmp }}"
when :
- openstack_keys_tmp is defined
2018-05-22 22:41:40 +08:00
# Create the pools listed in openstack_pools
- name : include openstack_config.yml
include : openstack_config.yml
when :
- openstack_config
2018-05-23 11:07:38 +08:00
- inventory_hostname == groups[osd_group_name] | last