change template to be more flexible
Signed-off-by: Alexandre Marangone <alexandre.marangone@inktank.com>
This commit is contained in:
parent
5d947a9c81
commit
973108c4c6
@ -1,30 +1,35 @@
|
|||||||
[global]
|
[global]
|
||||||
auth supported = cephx
|
fsid = <%= node["ceph"]["config"]["fsid"] %>
|
||||||
keyring = /etc/ceph/$cluster.$name.keyring
|
mon initial members = <%= node["ceph"]["config"]["mon_initial_members"] %>
|
||||||
|
mon host = <%= @mon_addresses.join(', ') %>
|
||||||
# this will be used by all clients to discover the mons to
|
<% if (! node['ceph']['config']['global'].nil?) -%>
|
||||||
# talk to; this way we don't need to have separate [mon.foo]
|
<% node['ceph']['config']['global'].each do |k, v| %>
|
||||||
# sections, and come up with names for the mons just to be
|
|
||||||
# able to list their addresses
|
|
||||||
mon host = <%= @mon_addresses.join(', ') %>
|
|
||||||
|
|
||||||
<% node['ceph']['config'].each do |k, v| %>
|
|
||||||
<%= k %> = <%= v %>
|
<%= k %> = <%= v %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
[mon]
|
<% if (! node['ceph']['config']['osd'].nil?) -%>
|
||||||
keyring = /var/lib/ceph/mon/$cluster-$id/keyring
|
|
||||||
|
|
||||||
[mds]
|
|
||||||
keyring = /var/lib/ceph/mds/$cluster-$id/keyring
|
|
||||||
|
|
||||||
[osd]
|
[osd]
|
||||||
keyring = /var/lib/ceph/osd/$cluster-$id/keyring
|
<% node['ceph']['config']['osd'].each do |k, v| %>
|
||||||
osd journal size = 1000
|
<%= k %> = <%= v %>
|
||||||
filestore_xattr_use_omap = true
|
<% end %>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
|
<% if (! node['ceph']['config']['mon'].nil?) -%>
|
||||||
|
[mon]
|
||||||
|
<% node['ceph']['config']['mon'].each do |k, v| %>
|
||||||
|
<%= k %> = <%= v %>
|
||||||
|
<% end %>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
|
<% if (! node['ceph']['config']['mds'].nil?) -%>
|
||||||
|
[mds]
|
||||||
|
<% node['ceph']['config']['mds'].each do |key, value| -%>
|
||||||
|
<%= key %> = <%= value %>
|
||||||
|
<% end -%>
|
||||||
|
<% end -%>
|
||||||
|
|
||||||
<% node['ceph']['config-sections'].each do |name, sect| %>
|
<% node['ceph']['config-sections'].each do |name, sect| %>
|
||||||
|
|
||||||
[<%= name %>]
|
[<%= name %>]
|
||||||
<% sect.each do |k, v| %>
|
<% sect.each do |k, v| %>
|
||||||
<%= k %> = <%= v %>
|
<%= k %> = <%= v %>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user