Displaying 20 results from an estimated 33 matches for "vms_service".
2018 Aug 07
1
[PATCH] v2v: -o rhv-upload: Properly replace SD_UUID in OVF (RHBZ#1612653).
...pload-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.18.0
2019 Sep 16
0
[PATCH 1/8] v2v: -o rhv-upload: split vmcheck out of precheck
...precheck.py b/v2v/rhv-upload-precheck.py
index b79f91b4a..6253c26ac 100644
--- a/v2v/rhv-upload-precheck.py
+++ b/v2v/rhv-upload-precheck.py
@@ -60,16 +60,6 @@ connection = sdk.Connection(
system_service = connection.system_service()
-# Find if a virtual machine already exists with that name.
-vms_service = system_service.vms_service()
-vms = vms_service.list(
- search = ("name=%s" % params['output_name']),
-)
-if len(vms) > 0:
- vm = vms[0]
- raise RuntimeError("VM already exists with name ‘%s’, id ‘%s’" %
- (params['output_name'...
2019 Sep 16
0
[PATCH 3/8] v2v: -o rhv-upload: improve lookup of specified resources (RHBZ#1612653)
...sds_service.list(search=("name=%s" % params['output_storage']))[0]
-sd_uuid = sd.id
-
-ovf = ovf.replace("@SD_UUID@", sd_uuid)
+# Get the cluster.
+cluster = system_service.clusters_service().cluster_service(params['rhv_cluster_uuid'])
+cluster = cluster.get()
vms_service = system_service.vms_service()
vm = vms_service.add(
types.Vm(
- cluster=types.Cluster(name = params['rhv_cluster']),
+ cluster=cluster,
initialization=types.Initialization(
configuration = types.Configuration(
type = types.Configur...
2019 Apr 15
1
[PATCH] v2v: -o rhv-upload: check whether the cluster exists
...39,9 @@ class Connection(object):
return SystemService()
class SystemService(object):
+ def clusters_service(self):
+ return ClustersService()
+
def data_centers_service(self):
return DataCentersService()
@@ -54,6 +57,10 @@ class SystemService(object):
def vms_service(self):
return VmsService()
+class ClustersService(object):
+ def list(self, search=None, case_sensitive=False):
+ return ["Default"]
+
class DataCentersService(object):
def list(self, search=None, case_sensitive=False):
return []
--
2.20.1
2019 Sep 16
16
[PATCH 0/8] v2v: various fixed for -o rhv-upload
This patch series fixes various issues in the rhv-upload output mode:
- properly find and use RHV resources
- cleanup orphan disks, and possibly the current disk transfer on
failure
In reality, the first 4 patches deal with resources, and the other 4
with cleanups. The latter block can be theoretically sent alone --
I just happened to start working on it as part of my "let's fix
2020 Jan 10
7
[v2v PATCH 0/6] Various Python pycodestyle fixes
Fixes the majority of the pycodestyle issues in the Python scripts, and
fix the existing test-v2v-python-syntax.sh to use pycodestyle to
actually perform style checks.
Pino Toscano (6):
PEP 8: adapt whitespaces in lines
PEP 8: move imports at the top
PEP 8: adapt empty lines
tests: find all the Python scripts for syntax checks
-o rhv-upload: remove unused Python imports
Revamp check
2018 Feb 22
0
[PATCH 5/5] v2v: Add -o rhv-upload output mode.
...cleanup
+transfer_service.finalize()
+connection.close()
+proxy_connection.close()
+" (py_quote disk_id)
+ (py_bool true(*direct_upload XXX*))
+ (py_quote "/tmp/ca.pem"(*cafile XXX*))
+ (py_quote filename)
+ disk_size
+
+let python_create_virtual_machine ovf =
+ sprintf "
+vms_service = system_service.vms_service()
+vm = vms_service.add(
+ types.Vm(
+ cluster=types.Cluster(name = %s),
+ initialization=types.Initialization(
+ configuration = types.Configuration(
+ type = types.ConfigurationType.OVA,
+ data = %s
+...
2018 Mar 08
6
[PATCH v5 0/4] v2v: Add -o rhv-upload output mode.
Mainly minor fixes and code cleanups over the v4 patch.
There are still several problems with this patch, but it is in a
reviewable state, especially the Python code.
Rich.
2018 Mar 08
0
[PATCH v5 4/4] v2v: Add -o rhv-upload output mode.
...system_service()
+
+# Get the storage domain UUID and substitute it into the OVF doc.
+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)
+
+vms_service = system_service.vms_service()
+vm = vms_service.add(
+ types.Vm(
+ cluster=types.Cluster(name = "Default"), # XXX
+ initialization=types.Initialization(
+ configuration = types.Configuration(
+ type = types.ConfigurationType.OVA,
+...
2018 Feb 27
0
[PATCH v2 3/3] v2v: Add -o rhv-upload output mode.
....reason))
+
+# Successful cleanup
+transfer_service.finalize()
+connection.close()
+proxy_connection.close()
+" (py_quote disk_id)
+ ovirt_timeout
+ (py_bool rhv_direct)
+ (py_quote rhv_cafile)
+ (py_quote filename)
+ disk_size
+
+let python_create_virtual_machine ovf =
+ sprintf "
+vms_service = system_service.vms_service()
+vm = vms_service.add(
+ types.Vm(
+ cluster=types.Cluster(name = %s),
+ initialization=types.Initialization(
+ configuration = types.Configuration(
+ type = types.ConfigurationType.OVA,
+ data = %s
+...
2018 Mar 08
2
Re: [PATCH v5 4/4] v2v: Add -o rhv-upload output mode.
...ge domain UUID and substitute it into the OVF doc.
> +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)
> +
> +vms_service = system_service.vms_service()
> +vm = vms_service.add(
> + types.Vm(
> + cluster=types.Cluster(name = "Default"), # XXX
> + initialization=types.Initialization(
> + configuration = types.Configuration(
> + type = types.Configur...
2018 Feb 27
5
[PATCH v2 0/3] v2v: Add -o rhv-upload output mode.
This patch set is still for discussion only. See 3/3 for the current
list of problems.
However this will upload an image to an oVirt or RHV server, although
you must have absolutely the latest snapshot version of 4.2 for it to
work.
Rich.
2018 Mar 11
2
Re: [PATCH v5 4/4] v2v: Add -o rhv-upload output mode.
...ge domain UUID and substitute it into the OVF doc.
> +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)
> +
> +vms_service = system_service.vms_service()
> +vm = vms_service.add(
> + types.Vm(
> + cluster=types.Cluster(name = "Default"), # XXX
> + initialization=types.Initialization(
> + configuration = types.Configuration(
> + type = types.Configur...
2018 Mar 09
1
Re: [PATCH v5 4/4] v2v: Add -o rhv-upload output mode.
....
> +sds_service = system_service.storage_domains_service()
> +sd = sds_service.list(search=("name=%s" % params['output_storage']))[0]
> +sd_uuid = sd.id <http://sd.id>
> +
> +ovf.replace("@SD_UUID@", sd_uuid)
> +
> +vms_service = system_service.vms_service()
> +vm = vms_service.add(
> + types.Vm(
> + cluster=types.Cluster(name = "Default"), # XXX
> + initialization=types.Initialization(
> + configuration = types.Configuration(
> + ...
2018 Feb 22
2
Re: [PATCH 5/5] v2v: Add -o rhv-upload output mode.
...close()
> +proxy_connection.close()
> +" (py_quote disk_id)
> + (py_bool true(*direct_upload XXX*))
> + (py_quote "/tmp/ca.pem"(*cafile XXX*))
> + (py_quote filename)
> + disk_size
> +
> +let python_create_virtual_machine ovf =
> + sprintf "
> +vms_service = system_service.vms_service()
> +vm = vms_service.add(
> + types.Vm(
> + cluster=types.Cluster(name = %s),
> + initialization=types.Initialization(
> + configuration = types.Configuration(
> + type = types.ConfigurationType.OVA,
> +...
2018 Mar 21
2
[PATCH v6] v2v: Add -o rhv-upload output mode.
v5 was here:
https://www.redhat.com/archives/libguestfs/2018-March/msg00032.html
There is only a single patch in this version because the other
patches went upstream.
This patch adds the virt-v2v -o rhv-upload mode
(https://bugzilla.redhat.com/show_bug.cgi?id=1557273).
Compared to v5, this adds the ability to make zero, trim and flush
requests to the oVirt imageio server
2018 Mar 21
0
[PATCH v6] v2v: Add -o rhv-upload output mode.
...system_service()
+
+# Get the storage domain UUID and substitute it into the OVF doc.
+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)
+
+vms_service = system_service.vms_service()
+vm = vms_service.add(
+ types.Vm(
+ cluster=types.Cluster(name = params['rhv_cluster']),
+ initialization=types.Initialization(
+ configuration = types.Configuration(
+ type = types.ConfigurationType.OVA,
+...
2018 Feb 22
11
[PATCH 0/5] v2v: Add -o rhv-upload output mode.
The first four patches are straightforward.
The final patch adds the -o rhv-upload output mode. It is
still spooling into a temporary file because I've had some
trouble getting streaming conversions working. There are
other problems as outlined in the commit message, so this
patch is not ready for upstream but is good for discussion.
Also I hit this, which I'm assuming for now will be
2018 Mar 22
0
[PATCH v7 6/6] v2v: Add -o rhv-upload output mode (RHBZ#1557273).
...system_service()
+
+# Get the storage domain UUID and substitute it into the OVF doc.
+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)
+
+vms_service = system_service.vms_service()
+vm = vms_service.add(
+ types.Vm(
+ cluster=types.Cluster(name = params['rhv_cluster']),
+ initialization=types.Initialization(
+ configuration = types.Configuration(
+ type = types.ConfigurationType.OVA,
+...
2018 Apr 05
2
[PATCH v8] v2v: Add -o rhv-upload output mode (RHBZ#1557273).
v7 was here:
https://www.redhat.com/archives/libguestfs/2018-March/msg00143.html
Since then:
- Earlier patches are now upstream.
- The to-do list is moved from the commit message to the TODO file.
- This version forces -of raw + -oa sparse and gives an error in
any other mode. We intend to lift these restrictions later.
- Tested against latest imageio which supports longer timeouts,