From 8e1436d4afaeb72440157a81fc98abd98b3badcc Mon Sep 17 00:00:00 2001
From: Georg Pfuetzenreuter
Date: Sun, 12 Feb 2023 03:57:52 +0100
Subject: common.suse: manage qemu-guest-agent

Ensure qemu-guest-agent is active on all KVM guests.

Signed-off-by: Georg Pfuetzenreuter <mail@georg-pfuetzenreuter.net>
---
 salt/common/suse.sls | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/salt/common/suse.sls b/salt/common/suse.sls
index baf0167..e260c77 100644
--- a/salt/common/suse.sls
+++ b/salt/common/suse.sls
@@ -46,6 +46,15 @@ common_packages_install:
     - names:
       - fish
       - system-group-wheel
+{%- if grains['virtual'] == 'kvm' %}
+      - qemu-guest-agent
+
+qemu-guest-agent:
+  service.running:
+    - enable: True
+    - require:
+      - pkg: qemu-guest-agent
+{%- endif %}
 
 common_packages_remove:
   pkg.removed:
-- 
cgit v1.2.3