Blob Blame History Raw
From 739ac1bc0f37c4bceb2e2eeed00f9320605aa641 Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones@redhat.com>
Date: Tue, 7 Aug 2018 09:06:46 +0100
Subject: [PATCH] v2v: -o rhv-upload: Properly replace SD_UUID in OVF
 (RHBZ#1612653).

The @SD_UUID@ pattern was not being replaced correctly.

Thanks: Daniel Erez.
(cherry picked from commit 389e165519c33b5234db50ea26dcb267321ee152)
---
 v2v/rhv-upload-createvm.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/v2v/rhv-upload-createvm.py b/v2v/rhv-upload-createvm.py
index a34627ec8..1d0e8c95d 100644
--- a/v2v/rhv-upload-createvm.py
+++ b/v2v/rhv-upload-createvm.py
@@ -70,7 +70,7 @@ sds_service = system_service.storage_domains_service()
 sd = sds_service.list(search=("name=%s" % params['output_storage']))[0]
 sd_uuid = sd.id
 
-ovf.replace("@SD_UUID@", sd_uuid)
+ovf = ovf.replace("@SD_UUID@", sd_uuid)
 
 vms_service = system_service.vms_service()
 vm = vms_service.add(
-- 
2.21.0