Blame SOURCES/0071-v2v-rhv-plugin-fix-DC-search-string.patch

e9bfca
From f28a96fadc0997687deaa01652ad80b37b08d657 Mon Sep 17 00:00:00 2001
e9bfca
From: Daniel Erez <derez@redhat.com>
e9bfca
Date: Tue, 24 Jul 2018 19:16:10 +0300
e9bfca
Subject: [PATCH] v2v: rhv plugin - fix DC search string
e9bfca
e9bfca
Search for DC by 'storage.name=' to make it explicit.
e9bfca
I.e. "storage=" uses regex, so similar names can be
e9bfca
found in the search query. For example, searching for
e9bfca
a domain named FCSD, will find FCSD1 as well.
e9bfca
---
e9bfca
 v2v/rhv-upload-plugin.py | 2 +-
e9bfca
 1 file changed, 1 insertion(+), 1 deletion(-)
e9bfca
e9bfca
diff --git a/v2v/rhv-upload-plugin.py b/v2v/rhv-upload-plugin.py
e9bfca
index 931fcfaa2..8274f1ee1 100644
e9bfca
--- a/v2v/rhv-upload-plugin.py
e9bfca
+++ b/v2v/rhv-upload-plugin.py
e9bfca
@@ -72,7 +72,7 @@ def find_host(connection):
e9bfca
     system_service = connection.system_service()
e9bfca
     storage_name = params['output_storage']
e9bfca
     data_centers = system_service.data_centers_service().list(
e9bfca
-        search='storage=%s' % storage_name,
e9bfca
+        search='storage.name=%s' % storage_name,
e9bfca
         case_sensitive=False,
e9bfca
     )
e9bfca
     if len(data_centers) == 0:
e9bfca
-- 
e9bfca
2.17.1
e9bfca