Merge pull request #239 from leseb/upstart-sysvinit

Rework upstart and sysvinit
pull/240/head
Leseb 2015-03-30 11:39:01 +02:00
commit e9dc0e13ec
4 changed files with 77 additions and 6 deletions

View File

@ -34,9 +34,42 @@
group=root
when: cephx
- name: Start and add that the MDS service to the init sequence
- name: Activate metadata server with upstart
file: >
path=/var/lib/ceph/mds/ceph-{{ ansible_hostname }}/{{ item }}
state=touch
owner=root
group=root
mode=0600
with_items:
- done
- upstart
when: ansible_distribution == "Ubuntu"
- name: Activate metadata server with sysvinit
file: >
path=/var/lib/ceph/mds/ceph-{{ ansible_hostname }}/{{ item }}
state=touch
owner=root
group=root
mode=0600
with_items:
- done
- sysvinit
when: ansible_distribution != "Ubuntu"
- name: Start and add that the metadata service to the init sequence (Ubuntu)
service: >
name=ceph-mds
state=started
enabled=yes
args="id={{ ansible_hostname }}"
when: ansible_distribution == "Ubuntu"
- name: Start and add that the metadata service to the init sequence
service: >
name=ceph
state=started
enabled=yes
args=mds
when: ansible_distribution != "Ubuntu"

View File

@ -4,10 +4,10 @@
when: not ceph_containerized_deployment
- include: install_redhat.yml
when: ansible_os_family == 'RedHat' and radosgw_frontend == 'apache'
when: ansible_os_family == 'RedHat' and radosgw_frontend == 'apache' and not ceph_containerized_deployment
- include: install_debian.yml
when: ansible_os_family == 'Debian' and radosgw_frontend == 'apache'
when: ansible_os_family == 'Debian' and radosgw_frontend == 'apache' and not ceph_containerized_deployment
- name: "Install Rados Gateway"
apt: >
@ -23,6 +23,7 @@
when: ansible_os_family == 'RedHat' and not ceph_containerized_deployment
- include: start_radosgw.yml
when: not ceph_containerized_deployment
- include: docker.yml
when: ceph_containerized_deployment

View File

@ -18,8 +18,12 @@
- name: Activate RGW with upstart
file: >
path=/var/lib/ceph/radosgw/ceph-radosgw.{{ ansible_fqdn }}/done
path=/var/lib/ceph/radosgw/ceph-radosgw.{{ ansible_fqdn }}/{{ item }}
state=touch
owner=root
group=root
mode=0644
with_items:
- done
- upstart
when: ansible_distribution == "Ubuntu"

View File

@ -18,8 +18,41 @@
- name: Activate Ceph REST API with upstart
file: >
path=/var/lib/ceph/restapi/ceph-restapi/done
path=/var/lib/ceph/restapi/{{ item }}
state=touch
owner=root
group=root
mode=0644
mode=0600
with_items:
- done
- upstart
when: ansible_distribution == "Ubuntu"
- name: Activate Ceph REST API with sysvinit
file: >
path=/var/lib/ceph/restapi/{{ item }}
state=touch
owner=root
group=root
mode=0600
with_items:
- done
- sysvinit
when: ansible_distribution != "Ubuntu"
# NOTE (leseb): will uncomment this when this https://github.com/ceph/ceph/pull/4144 lands
#- name: Start and add that the Ceph REST API service to the init sequence (Ubuntu)
# service: >
# name=ceph-restapi
# state=started
# enabled=yes
# args="id={{ ansible_hostname }}"
# when: ansible_distribution == "Ubuntu"
#
#- name: Start and add that the Ceph REST API service to the init sequence
# service: >
# name=ceph
# state=started
# enabled=yes
# args=restapi
# when: ansible_distribution != "Ubuntu"