From 059439095315cef7bc965108d7edb96dd30b240e Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Wed, 23 Mar 2016 17:49:59 +0100 Subject: (virt_technology) introduce it --- perl-install/detect_devices.pm | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'perl-install/detect_devices.pm') diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm index b46fef8d2..4740cbe91 100644 --- a/perl-install/detect_devices.pm +++ b/perl-install/detect_devices.pm @@ -1471,6 +1471,17 @@ sub is_xbox() { any { $_->{vendor} == 0x10de && $_->{id} == 0x02a5 } pci_probe(); } +=item virt_technology() + +Returns the virtualization technology (eg: kvm, oracle, ...) + +=cut + +sub virt_technology() { + state $tech; + $tech ||= chomp_(run_program::get_stdout('systemd-detect-virt')); +} + =item is_virtualbox() Are we running under VirtualBox hypervisor? -- cgit v1.2.1