From 77ee0b823341417f2ce03be79f8bb2351ecc0d60 Mon Sep 17 00:00:00 2001 From: karmab Date: Fri, 17 Apr 2020 18:36:44 +0200 Subject: [PATCH] fix parsing of profile images within plan --- kvirt/config.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/kvirt/config.py b/kvirt/config.py index 34472debc..86e8e7e8b 100644 --- a/kvirt/config.py +++ b/kvirt/config.py @@ -1443,7 +1443,10 @@ def plan(self, plan, ansible=False, url=None, path=None, autostart=False, contai os.remove("%s.key" % plan) if 'image' in profile: for entry in self.list_profiles(): - if entry[0] == profile['image']: + currentimage = profile['image'] + profilename = entry[0] + clientprofile = "%s_%s" % (self.client, currentimage) + if profilename == currentimage or profilename == clientprofile: profile['image'] = entry[4] break result = self.create_vm(name, profilename, overrides=overrides, customprofile=profile, k=z,