Class: Setting::ForemanChef

Inherits:
Setting
  • Object
show all
Defined in:
app/models/setting/foreman_chef.rb

Class Method Summary collapse

Class Method Details

.humanized_categoryObject



18
19
20
# File 'app/models/setting/foreman_chef.rb', line 18

def self.humanized_category
  _('Chef')
end

.load_defaultsObject



3
4
5
6
7
8
9
10
11
12
13
14
15
16
# File 'app/models/setting/foreman_chef.rb', line 3

def self.load_defaults
  # Check the table exists
  return unless super

  self.transaction do
    [
        self.set('auto_deletion', N_("Enable the auto deletion of mapped objects in chef-server through foreman-proxy (currently node and client upon host deletion, client on host rebuild)"), true),
        self.set('validation_bootstrap_method', N_("Use validation.pem or create client directly storing private key in Foreman DB)"), true),
    ].each { |s| self.create! s.update(:category => "Setting::ForemanChef")}
  end

  true

end