[virt facts] identify KubeVirt properly (#72092)
Change: - Make KubeVirt be identified as such, and with a guest role. - This is a breaking change, since playbooks could be relying on the incorrect behavior previously. Test Plan: - Issue author Tickets: - Fixes #72001 Signed-off-by: Rick Elrod <rick@elrod.me>
This commit is contained in:
parent
0332046699
commit
a90e37d017
2 changed files with 8 additions and 0 deletions
2
changelogs/fragments/kubevirt-virt-fact.yml
Normal file
2
changelogs/fragments/kubevirt-virt-fact.yml
Normal file
|
@ -0,0 +1,2 @@
|
|||
bugfixes:
|
||||
- virtual facts - kubevirt is now identified as "KubeVirt" and with a "guest" role instead of "kvm" and "host" role (https://github.com/ansible/ansible/issues/72001).
|
|
@ -187,6 +187,12 @@ class LinuxVirtual(Virtual):
|
|||
virtual_facts['virtualization_type'] = 'kvm'
|
||||
found_virt = True
|
||||
|
||||
if sys_vendor == 'KubeVirt':
|
||||
guest_tech.add('KubeVirt')
|
||||
if not found_virt:
|
||||
virtual_facts['virtualization_type'] = 'KubeVirt'
|
||||
found_virt = True
|
||||
|
||||
# FIXME: This does also match hyperv
|
||||
if sys_vendor == 'Microsoft Corporation':
|
||||
guest_tech.add('VirtualPC')
|
||||
|
|
Loading…
Add table
Reference in a new issue