Revision e20f5716
Added by Ohad Levy over 12 years ago
- ID e20f5716d0a13f1bb4d54e64229947a4975c22b0
app/models/host.rb | ||
---|---|---|
# maybe these should be moved to the common parameters, leaving them in for now
|
||
param["puppetmaster"] = puppetmaster.to_s
|
||
param["domainname"] = domain.fullname unless domain.nil? or domain.fullname.nil?
|
||
param["hostgroup"] = hostgroup.name unless hostgroup.nil?
|
||
param["root_pw"] = root_pass if SETTINGS[:unattended]
|
||
param["foreman_env"] = environment.to_s unless environment.nil? or environment.name.nil?
|
||
if SETTINGS[:login]
|
||
param["owner_name"] = owner.name
|
||
param["owner_email"] = owner.is_a?(User) ? owner.mail : owner.users.map(&:mail)
|
||
end
|
||
|
||
if Setting[:ignore_puppet_facts_for_provisioning]
|
||
param["ip"] = ip
|
||
param["mac"] = mac
|
||
... | ... | |
info_hash = {}
|
||
info_hash['classes'] = self.puppetclasses_names
|
||
info_hash['parameters'] = param
|
||
info_hash['environment'] = environment.to_s unless environment.nil? or environment.name.nil?
|
||
info_hash['environment'] = param["foreman_env"]
|
||
|
||
return info_hash
|
||
end
|
Also available in: Unified diff
fixes #1179 - exposes foreman attributes in enc
this includes: