When creating pool, read pool.application and make the call to ceph osd pool enable application

Signed-off-by: Radu Toader <radu.m.toader@gmail.com>
pull/3660/head
Radu Toader 2019-02-28 18:46:29 +02:00 committed by mergify[bot]
parent b11dc13476
commit 2048255f61
3 changed files with 13 additions and 0 deletions

View File

@ -23,6 +23,7 @@ dummy:
# pg_num: "{{ osd_pool_default_pg_num }}"
# pgp_num: "{{ osd_pool_default_pg_num }}"
# rule_name: "replicated_rule"
# application: "rbd"
# type: 1
# erasure_profile: ""
# expected_num_objects: ""
@ -32,6 +33,7 @@ dummy:
# pg_num: "{{ osd_pool_default_pg_num }}"
# pgp_num: "{{ osd_pool_default_pg_num }}"
# rule_name: "replicated_rule"
# application: "rbd"
# type: 1
# erasure_profile: ""
# expected_num_objects: ""

View File

@ -15,6 +15,7 @@ test:
pg_num: "{{ osd_pool_default_pg_num }}"
pgp_num: "{{ osd_pool_default_pg_num }}"
rule_name: "replicated_rule"
application: "rbd"
type: 1
erasure_profile: ""
expected_num_objects: ""
@ -24,6 +25,7 @@ test2:
pg_num: "{{ osd_pool_default_pg_num }}"
pgp_num: "{{ osd_pool_default_pg_num }}"
rule_name: "replicated_rule"
application: "rbd"
type: 1
erasure_profile: ""
expected_num_objects: ""

View File

@ -113,6 +113,15 @@
- pools | length > 0
- item.size | default(osd_pool_default_size) != ceph_osd_pool_default_size
- name: assign application to pool(s)
command: "{{ docker_exec_cmd | default('') }} ceph --cluster {{ cluster }} osd pool application enable {{ item.name }} {{ item.application }}"
with_items: "{{ pools | unique }}"
changed_when: false
delegate_to: "{{ delegated_node }}"
when:
- item.application is defined
- name: get client cephx keys
copy:
dest: "{{ item.source }}"