Skip to content

Commit

Permalink
Allow default to be aka version 1 for pool creation
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris Jones committed Apr 29, 2017
1 parent 3de1a15 commit 5e39e49
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions libraries/ceph_chef_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def ceph_chef_pool_create(pool)
profile_val = pool_val['profile'] if type_val == 'erasure'
crush_ruleset_name = pool_val['crush_ruleset_name']

if node['ceph']['pools']['version'] == 1
if node['ceph']['pools']['version'] != 2
ceph_chef_pool name do
action :create
pg_num pg_num_val
Expand Down Expand Up @@ -104,7 +104,7 @@ def ceph_chef_pool_create(pool)
crush_ruleset_name = pool_val['crush_ruleset_name']
options_val = node['ceph']['pools'][pool]['settings']['options'] if node['ceph']['pools'][pool]['settings']['options']

if node['ceph']['pools']['version'] == 1
if node['ceph']['pools']['version'] != 2
ceph_chef_pool pool_val['name'] do
action :create
pg_num pg_num_val
Expand Down Expand Up @@ -145,7 +145,7 @@ def ceph_chef_pool_set(pool)
node['ceph']['osd']['size']['max']
end

if node['ceph']['pools']['version'] == 1
if node['ceph']['pools']['version'] != 2
ceph_chef_pool name do
action :set
key 'size'
Expand All @@ -170,7 +170,7 @@ def ceph_chef_pool_set(pool)
node['ceph']['osd']['size']['max']
end

if node['ceph']['pools']['version'] == 1
if node['ceph']['pools']['version'] != 2
ceph_chef_pool pool_val['name'] do
action :set
key 'size'
Expand Down

0 comments on commit 5e39e49

Please sign in to comment.