Skip to content

Commit

Permalink
Add distribution version fact
Browse files Browse the repository at this point in the history
  • Loading branch information
ShimShtein authored and ronlavi2412 committed Nov 18, 2019
1 parent eeae222 commit 666246e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/foreman_inventory_upload/generators/queries.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def self.fact_names
'distribution::name',
'uname::release',
'lscpu::flags',
'distribution::version',
]).pluck(:name, :id)
]
end
Expand Down
1 change: 1 addition & 0 deletions lib/foreman_inventory_upload/generators/slice.rb
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ def report_satellite_facts(host)
end
@stream.simple_field('system_purpose_usage', host.subscription_facet.purpose_usage)
@stream.simple_field('system_purpose_role', host.subscription_facet.purpose_role)
@stream.simple_field('distribution_version', fact_value(host, 'distribution::version'))
@stream.simple_field('satellite_instance_id', Foreman.respond_to?(:instance_id) ? Foreman.instance_id : nil)
@stream.simple_field('organization_id', host.organization_id, :last)
end
Expand Down

0 comments on commit 666246e

Please sign in to comment.