mirror of https://github.com/ceph/ceph-ansible.git
33 lines
771 B
YAML
33 lines
771 B
YAML
---
|
|
- name: check if rgw is started
|
|
command: /etc/init.d/radosgw status
|
|
register: rgwstatus
|
|
changed_when: false
|
|
failed_when: false
|
|
|
|
- name: start rgw
|
|
command: /etc/init.d/radosgw start
|
|
when:
|
|
rgwstatus.rc != 0 and
|
|
ansible_distribution != "Ubuntu" and
|
|
ansible_os_family != 'RedHat'
|
|
|
|
- name: activate rgw on ubuntu
|
|
command: initctl emit radosgw cluster=ceph id=rgw.{{ ansible_hostname }}
|
|
changed_when: false
|
|
when: ansible_distribution == 'Ubuntu'
|
|
|
|
- name: start rgw on ubuntu
|
|
service: >
|
|
name=radosgw
|
|
args=id=rgw.{{ ansible_hostname }}
|
|
state=started
|
|
when: ansible_distribution == 'Ubuntu'
|
|
|
|
- name: start rgw on red hat
|
|
service: >
|
|
name=ceph-radosgw
|
|
state=started
|
|
enabled=yes
|
|
when: ansible_distribution == 'RedHat'
|