summaryrefslogtreecommitdiffstats
path: root/deploy/adapters/ansible/roles/ceph-mon/tasks
diff options
context:
space:
mode:
authorgrakiss <grakiss.wanglei@huawei.com>2016-02-15 22:14:45 -0500
committergrakiss <grakiss.wanglei@huawei.com>2016-02-24 01:54:19 -0500
commite72bc045fd467a442a0ffb1c78e710a270a59dfa (patch)
treede36cb10caf65af125d3815733c92abd561d8866 /deploy/adapters/ansible/roles/ceph-mon/tasks
parent00ba12cbc900cb1cb38bee938544cc95583ab416 (diff)
Support version Liberty of OpenStack for CENTOS7
JIRA:COMPASS-315 -Support version Liberty of OpenStack for CENTOS7 Change-Id: I81abbb37a295a0ea733398ad1f278bafc3525d87 Signed-off-by: grakiss <grakiss.wanglei@huawei.com>
Diffstat (limited to 'deploy/adapters/ansible/roles/ceph-mon/tasks')
-rw-r--r--deploy/adapters/ansible/roles/ceph-mon/tasks/install_mon.yml14
1 files changed, 8 insertions, 6 deletions
diff --git a/deploy/adapters/ansible/roles/ceph-mon/tasks/install_mon.yml b/deploy/adapters/ansible/roles/ceph-mon/tasks/install_mon.yml
index 3b818ea2..658d109e 100644
--- a/deploy/adapters/ansible/roles/ceph-mon/tasks/install_mon.yml
+++ b/deploy/adapters/ansible/roles/ceph-mon/tasks/install_mon.yml
@@ -7,20 +7,22 @@
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
+- include_vars: "{{ ansible_os_family }}.yml"
+
- name: Create a default data directory
file: path="/var/lib/ceph/mon/ceph-{{ inventory_hostname }}" state="directory"
- name: Populate the monitor daemon
shell: "ceph-mon --mkfs -i {{ inventory_hostname }} --monmap /tmp/monmap --keyring /tmp/ceph.mon.keyring"
-- name: Touch the done file
- file: path="/var/lib/ceph/mon/ceph-{{ inventory_hostname }}/done" state="touch"
+- name: Touch the done and auto start file
+ file: path="/var/lib/ceph/mon/ceph-{{ inventory_hostname }}/{{ item }}" state="touch"
+ with_items:
+ - "done"
+ - "{{ ceph_start_type }}"
- name: start mon daemon
- shell: start ceph-mon id={{ inventory_hostname }}
-
-- name: auto start ceph-mon
- file: path="/var/lib/ceph/mon/ceph-{{ inventory_hostname }}/upstart" state="touch"
+ shell: "{{ ceph_start_script }}"
- name: wait for creating osd keyring
wait_for: path=/var/lib/ceph/bootstrap-osd/ceph.keyring