@@ -37,6 +37,8 @@ def run(test, params, env):
37
37
vpx_pwd_file = params .get ("vpx_passwd_file" )
38
38
vpx_dc = params .get ("vpx_dc" )
39
39
esx_ip = params .get ("esx_hostname" )
40
+ esxi_password = params .get ('esxi_password' )
41
+ src_uri_type = params .get ('src_uri_type' )
40
42
hypervisor = params .get ("hypervisor" )
41
43
input_mode = params .get ("input_mode" )
42
44
target = params .get ("target" )
@@ -58,10 +60,10 @@ def run(test, params, env):
58
60
59
61
if hypervisor == "esx" :
60
62
source_ip = vpx_ip
61
- source_pwd = vpx_pwd
63
+ source_pwd = vpx_pwd if src_uri_type != 'esx' else esxi_password
62
64
# Create password file to access ESX hypervisor
63
65
with open (vpx_pwd_file , 'w' ) as f :
64
- f .write (vpx_pwd )
66
+ f .write (source_pwd )
65
67
elif hypervisor == "xen" :
66
68
source_ip = xen_ip
67
69
source_pwd = xen_pwd
@@ -80,6 +82,8 @@ def run(test, params, env):
80
82
81
83
# Create libvirt URI for the source node
82
84
v2v_uri = utils_v2v .Uri (hypervisor )
85
+ if src_uri_type == 'esx' :
86
+ vpx_dc = None
83
87
remote_uri = v2v_uri .get_uri (source_ip , vpx_dc , esx_ip )
84
88
LOG .debug ("Remote host uri for converting: %s" , remote_uri )
85
89
@@ -124,6 +128,8 @@ def run(test, params, env):
124
128
'vddk_thumbprint' : vddk_thumbprint ,
125
129
'vddk_libdir' : vddk_libdir ,
126
130
'vddk_libdir_src' : vddk_libdir_src ,
131
+ 'esxi_password' : esxi_password ,
132
+ 'src_uri_type' : src_uri_type ,
127
133
'params' : params
128
134
}
129
135
if vpx_dc :
0 commit comments