]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
client: remove default value for pg_num in pools creation
authorGuillaume Abrioux <gabrioux@redhat.com>
Thu, 3 May 2018 19:36:21 +0000 (21:36 +0200)
committerSébastien Han <seb@redhat.com>
Wed, 16 May 2018 07:44:36 +0000 (09:44 +0200)
trying to set the default value for pg_num to
`hostvars[groups[mon_group_name][0]]['osd_pool_default_pg_num'])` will
break in case of external client nodes deployment.
the `pg_num` attribute should be mandatory and be tested in future
`ceph-validate` role.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
(cherry picked from commit f60b049ae53bbf54dd550587e84b986fef15fbe6)
Signed-off-by: Sébastien Han <seb@redhat.com>
roles/ceph-client/tasks/create_users_keys.yml

index d8ab3fd875bc11576f3c74b895ccb666a58613c2..43c90ad50dba71db40a759f791b73df84f22f029 100644 (file)
@@ -92,8 +92,8 @@
   command: >
     {{ docker_exec_cmd | default('') }} ceph --cluster {{ cluster }}
     osd pool create {{ item.0.name }}
-    {{ item.0.get('pg_num', hostvars[groups[mon_group_name][0]]['osd_pool_default_pg_num']) }}
-    {{ item.0.pgp_num | default(item.0.pg_num) }}
+    {{ item.0.pg_num }}
+    {{ item.0.pgp_num }}
     {{ 'replicated_rule' if item.0.rule_name | default('replicated_rule') == '' else item.0.rule_name | default('replicated_rule') }}
     {{ 1 if item.0.type|default(1) == 'replicated' else 3 if item.0.type|default(1) == 'erasure' else item.0.type|default(1) }}
     {%- if (item.0.type | default("1") == '3' or item.0.type | default("1") == 'erasure') and item.0.erasure_profile != '' %}