[bp-2.17] facts: Add a generic detection for VMware product name (#83023)

* Use startswith instead of hardcoded values in VMWare product
  detction

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
pull/83058/head
Abhijeet Kasurde 7 months ago committed by GitHub
parent 065918698d
commit ad2a1a5fbe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -0,0 +1,3 @@
---
bugfixes:
- facts - add a generic detection for VMware in product name.

@ -175,7 +175,7 @@ class LinuxVirtual(Virtual):
virtual_facts['virtualization_type'] = 'RHEV'
found_virt = True
if product_name in ('VMware Virtual Platform', 'VMware7,1', 'VMware20,1'):
if product_name and product_name.startswith(("VMware",)):
guest_tech.add('VMware')
if not found_virt:
virtual_facts['virtualization_type'] = 'VMware'

Loading…
Cancel
Save