From 4be84430e47dbd087cfccd37dea29d9444f43c9e Mon Sep 17 00:00:00 2001 From: Alex Schultz Date: Fri, 25 Oct 2019 14:22:24 -0600 Subject: [PATCH] Collect hardware facts if necessary for libvirt type We're seeing failures where ansible_processor is missing. We should try to do a hardware fact collection if ansible_processor is not defined before executing the set-libvirt-type role tasks Change-Id: I40ae758d687dd8f637c27c0e7acf76dbf60adb51 Closes-Bug: #1849895 --- roles/set-libvirt-type/tasks/main.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/roles/set-libvirt-type/tasks/main.yml b/roles/set-libvirt-type/tasks/main.yml index fa9255950..f09597c34 100644 --- a/roles/set-libvirt-type/tasks/main.yml +++ b/roles/set-libvirt-type/tasks/main.yml @@ -1,4 +1,8 @@ --- +- name: Collect hardware facts if necessary + setup: + gather_subset: "!all,!min,hardware" + when: ansible_processor is not defined - name: Check cpu vendor set_fact: cpu_vendor: "{{ item }}"