in libraries/ceph_chef_helper.rb [328:350]
def ceph_chef_fsid_secret
if node['ceph']['encrypted_data_bags']
secret = Chef::EncryptedDataBagItem.load_secret(node['ceph']['fsid']['secret_file'])
Chef::EncryptedDataBagItem.load('ceph', 'fsid', secret)['secret']
elsif !ceph_chef_mon_nodes.empty?
secret = ceph_chef_mon_nodes[0]['ceph']['fsid-secret']
if !secret.nil? && !secret.empty?
ceph_chef_save_fsid_secret(secret)
ceph_chef_mon_nodes[0]['ceph']['fsid-secret']
elsif node['ceph']['fsid-secret']
node['ceph']['fsid-secret']
else
Chef::Log.info('No fsid secret found')
nil
end
elsif node['ceph']['fsid-secret']
node['ceph']['fsid-secret']
else
Chef::Log.info('No fsid secret found')
nil
end
end