2015-07-28 23:15:19 +08:00
|
|
|
---
|
2016-06-03 06:54:56 +08:00
|
|
|
- name: generate systemd unit file
|
|
|
|
become: true
|
|
|
|
template:
|
2016-06-05 01:56:01 +08:00
|
|
|
src: "{{ role_path }}/templates/ceph-mds.service.j2"
|
2017-02-17 01:31:32 +08:00
|
|
|
dest: /etc/systemd/system/ceph-mds@.service
|
2016-06-03 06:54:56 +08:00
|
|
|
owner: "root"
|
|
|
|
group: "root"
|
|
|
|
mode: "0644"
|
|
|
|
|
|
|
|
- name: enable systemd unit file for mds instance
|
2017-02-17 01:31:32 +08:00
|
|
|
shell: systemctl enable ceph-mds@{{ ansible_hostname }}.service
|
2016-06-03 06:54:56 +08:00
|
|
|
failed_when: false
|
|
|
|
changed_when: false
|
|
|
|
|
|
|
|
- name: reload systemd unit files
|
2017-02-17 01:31:32 +08:00
|
|
|
shell: systemctl daemon-reload
|
2016-06-03 06:54:56 +08:00
|
|
|
changed_when: false
|
|
|
|
failed_when: false
|
|
|
|
|
|
|
|
- name: systemd start mds container
|
|
|
|
service:
|
|
|
|
name: ceph-mds@{{ ansible_hostname }}
|
|
|
|
state: started
|
|
|
|
enabled: yes
|
|
|
|
changed_when: false
|