class OvirtSDK4::ExternalTemplateImportsService
Constants
- ADD
Public Instance Methods
This operation is used to import a template from external hypervisor.
For example import of a template OVA can be facilitated using the following request:
- source
POST /externaltemplateimports
With request body of type xref:types-external_template_import, for example:
- source,xml
<external_template_import>
<template> <name>my_template</name> </template> <cluster id="2b18aca2-4469-11eb-9449-482ae35a5f83" /> <storage_domain id="8bb5ade5-e988-4000-8b93-dbfc6717fe50" /> <url>ova:///mnt/ova/ova_template.ova</url> <host id="8bb5ade5-e988-4000-8b93-dbfc6717fe50" />
</external_template_import>
@param import [ExternalTemplateImport] The `import` to add.
@param opts [Hash] Additional options.
@option opts [Hash] :headers ({}) Additional HTTP headers.
@option opts [Hash] :query ({}) Additional URL query parameters.
@option opts [Integer] :timeout (nil) The timeout for this request, in seconds. If no value is explicitly
given then the timeout set globally for the connection will be used.
@option opts [Boolean] :wait (true) If `true` wait for the response.
@return [ExternalTemplateImport]
# File lib/ovirtsdk4/services.rb, line 10318 def add(import, opts = {}) internal_add(import, ExternalTemplateImport, ADD, opts) end
Locates the service corresponding to the given path.
@param path [String] The path of the service.
@return [Service] A reference to the service.
# File lib/ovirtsdk4/services.rb, line 10329 def service(path) if path.nil? || path == '' return self end raise Error.new("The path \"#{path}\" doesn't correspond to any service") end