Skip to content

Commit

Permalink
(maint) When vendor is Amazon, hypervisors is kvm, when vendor is XEN…
Browse files Browse the repository at this point in the history
…, hypervisor is xen.
  • Loading branch information
BogdanIrimie committed Oct 8, 2020
1 parent 96db788 commit e547bcd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/facter/facts_utils/virtual_detector.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def check_dmi
@log.debug('Checking DMI')
vendor = Facter::Resolvers::DmiDecode.resolve(:vendor)
@log.debug("dmi detected vendor: #{vendor}")
return 'aws' if vendor =~ /Amazon/
return 'kvm' if vendor =~ /Amazon/

'xen' if vendor =~ /Xen/
end
Expand Down
2 changes: 1 addition & 1 deletion lib/facter/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Facter
VERSION = '4.0.42' unless defined?(VERSION)
VERSION = '4.0.45' unless defined?(VERSION)
end
2 changes: 1 addition & 1 deletion spec/facter/facts_utils/virtual_detector_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
end

it 'returns vendor' do
expect(detector.platform).to eq('aws')
expect(detector.platform).to eq('kvm')
end
end

Expand Down

0 comments on commit e547bcd

Please sign in to comment.