forked from contiv-experimental/volplugin
-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.yml
99 lines (84 loc) · 2.65 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
---
- include: ./checks/check_system.yml
- include: ./checks/check_mandatory_vars.yml
- include: ./misc/system_tuning.yml
when: osd_group_name in group_names
- include: ./pre_requisites/prerequisite_ice.yml
when: ceph_stable_ice
- include: ./pre_requisites/prerequisite_rh_storage_iso_install.yml
when:
ceph_stable_rh_storage and
ceph_stable_rh_storage_iso_install
- include: ./pre_requisites/prerequisite_rh_storage_cdn_install.yml
when:
ceph_stable_rh_storage and
ceph_stable_rh_storage_cdn_install
- include: ./installs/install_on_redhat.yml
when: ansible_os_family == 'RedHat'
- include: ./installs/install_on_debian.yml
when: ansible_os_family == 'Debian'
- include: ./installs/install_rgw_on_redhat.yml
when:
ansible_os_family == 'RedHat' and
radosgw_frontend == 'apache' and
rgw_group_name in group_names
- include: ./installs/install_rgw_on_debian.yml
when:
ansible_os_family == 'Debian' and
radosgw_frontend == 'apache' and
rgw_group_name in group_names
- name: create a local fetch directory if it doesn't exist
local_action: file path={{ fetch_directory }} state=directory
changed_when: false
sudo: false
run_once: true
- name: generate cluster uuid
local_action: shell uuidgen | tee {{ fetch_directory }}/ceph_cluster_uuid.conf
creates="{{ fetch_directory }}/ceph_cluster_uuid.conf"
register: cluster_uuid
sudo: false
when: fsid != '4a158d27-f750-41d5-9e7f-26ce4c9d2d45'
- name: read cluster uuid if it already exists
local_action: command cat {{ fetch_directory }}/ceph_cluster_uuid.conf
removes="{{ fetch_directory }}/ceph_cluster_uuid.conf"
changed_when: false
register: cluster_uuid
sudo: false
when: fsid != '4a158d27-f750-41d5-9e7f-26ce4c9d2d45'
- name: create ceph conf directory
file:
path: /etc/ceph
state: directory
owner: root
group: root
mode: 0644
- name: generate ceph configuration file
template:
src: ceph.conf.j2
dest: /etc/ceph/ceph.conf
owner: root
group: root
mode: 0644
notify:
- check for a ceph socket
- check for a rados gateway socket
- restart ceph mons
- restart ceph mons on ubuntu
- restart ceph mons with systemd
- restart ceph osds
- restart ceph osds on ubuntu
- restart ceph osds with systemd
- restart ceph mdss
- restart ceph mdss on ubuntu
- restart ceph mdss with systemd
- restart ceph rgws
- restart ceph rgws on ubuntu
- restart ceph rgws on red hat
- restart ceph rgws with systemd
- name: create rbd client directory
file:
path: "{{ rbd_client_admin_socket_path }}"
state: directory
owner: root
group: root
mode: 0644