diff --git a/group_vars/mons.sample b/group_vars/mons.sample index 9912848af..75f9daf27 100644 --- a/group_vars/mons.sample +++ b/group_vars/mons.sample @@ -40,6 +40,8 @@ dummy: # - nodelete # - nosizechange +# Enable the Calamari-backed REST API on a Monitor +#calamari: false ############# # OPENSTACK # diff --git a/roles/ceph-mon/defaults/main.yml b/roles/ceph-mon/defaults/main.yml index 39c5fa03d..ff638c18f 100644 --- a/roles/ceph-mon/defaults/main.yml +++ b/roles/ceph-mon/defaults/main.yml @@ -32,6 +32,8 @@ secure_cluster_flags: - nodelete - nosizechange +# Enable the Calamari-backed REST API on a Monitor +calamari: false ############# # OPENSTACK # diff --git a/roles/ceph-mon/tasks/calamari.yml b/roles/ceph-mon/tasks/calamari.yml new file mode 100644 index 000000000..5b0c34119 --- /dev/null +++ b/roles/ceph-mon/tasks/calamari.yml @@ -0,0 +1,19 @@ +--- +- name: install calamari server + apt: + pkg: calamari-server + state: present + when: ansible_os_family == 'Debian' + tags: + - package-install + +- name: install calamari server + yum: + pkg: calamari-server + state: present + when: ansible_os_family == 'RedHat' + tags: + - package-install + +- name: initialize the calamari server api + command: calamari-ctl initialize diff --git a/roles/ceph-mon/tasks/main.yml b/roles/ceph-mon/tasks/main.yml index ea3dada5b..085ec05b4 100644 --- a/roles/ceph-mon/tasks/main.yml +++ b/roles/ceph-mon/tasks/main.yml @@ -20,3 +20,6 @@ - include: ./docker/main.yml when: mon_containerized_deployment + +- include: calamari.yml + when: calamari