Class: OvirtSDK4::OpenstackVolumeProviderService
- Inherits:
-
ExternalProviderService
- Object
- Service
- ExternalProviderService
- OvirtSDK4::OpenstackVolumeProviderService
- Defined in:
- lib/ovirtsdk4/services.rb,
lib/ovirtsdk4/services.rb
Instance Method Summary collapse
-
#authentication_keys_service ⇒ OpenstackVolumeAuthenticationKeysService
Locates the
authentication_keys
service. -
#certificates_service ⇒ ExternalProviderCertificatesService
A service to view certificates for this external provider.
-
#get(opts = {}) ⇒ OpenStackVolumeProvider
Returns the representation of the object managed by this service.
-
#import_certificates(opts = {}) ⇒ Object
Import the SSL certificates of the external host provider.
-
#remove(opts = {}) ⇒ Object
Deletes the object managed by this service.
-
#service(path) ⇒ Service
Locates the service corresponding to the given path.
-
#test_connectivity(opts = {}) ⇒ Object
In order to test connectivity for external provider we need to run following request where 123 is an id of a provider.
-
#update(provider, opts = {}) ⇒ OpenStackVolumeProvider
Update the specified OpenStack volume provider in the system.
-
#volume_types_service ⇒ OpenstackVolumeTypesService
Locates the
volume_types
service.
Methods inherited from Service
Instance Method Details
#authentication_keys_service ⇒ OpenstackVolumeAuthenticationKeysService
Locates the authentication_keys
service.
18329 18330 18331 |
# File 'lib/ovirtsdk4/services.rb', line 18329 def authentication_keys_service @authentication_keys_service ||= OpenstackVolumeAuthenticationKeysService.new(self, 'authenticationkeys') end |
#certificates_service ⇒ ExternalProviderCertificatesService
A service to view certificates for this external provider.
18338 18339 18340 |
# File 'lib/ovirtsdk4/services.rb', line 18338 def certificates_service @certificates_service ||= ExternalProviderCertificatesService.new(self, 'certificates') end |
#get(opts = {}) ⇒ OpenStackVolumeProvider
Returns the representation of the object managed by this service.
18203 18204 18205 |
# File 'lib/ovirtsdk4/services.rb', line 18203 def get(opts = {}) internal_get(GET, opts) end |
#import_certificates(opts = {}) ⇒ Object
Import the SSL certificates of the external host provider.
18229 18230 18231 |
# File 'lib/ovirtsdk4/services.rb', line 18229 def import_certificates(opts = {}) internal_action(:importcertificates, nil, IMPORT_CERTIFICATES, opts) end |
#remove(opts = {}) ⇒ Object
Deletes the object managed by this service.
18259 18260 18261 |
# File 'lib/ovirtsdk4/services.rb', line 18259 def remove(opts = {}) internal_remove(REMOVE, opts) end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
18358 18359 18360 18361 18362 18363 18364 18365 18366 18367 18368 18369 18370 18371 18372 18373 18374 18375 18376 18377 18378 18379 18380 18381 |
# File 'lib/ovirtsdk4/services.rb', line 18358 def service(path) if path.nil? || path == '' return self end if path == 'authenticationkeys' return authentication_keys_service end if path.start_with?('authenticationkeys/') return authentication_keys_service.service(path[19..-1]) end if path == 'certificates' return certificates_service end if path.start_with?('certificates/') return certificates_service.service(path[13..-1]) end if path == 'volumetypes' return volume_types_service end if path.start_with?('volumetypes/') return volume_types_service.service(path[12..-1]) end raise Error.new("The path \"#{path}\" doesn't correspond to any service") end |
#test_connectivity(opts = {}) ⇒ Object
In order to test connectivity for external provider we need to run following request where 123 is an id of a provider.
POST /ovirt-engine/api/externalhostproviders/123/testconnectivity
18291 18292 18293 |
# File 'lib/ovirtsdk4/services.rb', line 18291 def test_connectivity(opts = {}) internal_action(:testconnectivity, nil, TEST_CONNECTIVITY, opts) end |
#update(provider, opts = {}) ⇒ OpenStackVolumeProvider
Update the specified OpenStack volume provider in the system.
18320 18321 18322 |
# File 'lib/ovirtsdk4/services.rb', line 18320 def update(provider, opts = {}) internal_update(provider, OpenStackVolumeProvider, UPDATE, opts) end |
#volume_types_service ⇒ OpenstackVolumeTypesService
Locates the volume_types
service.
18347 18348 18349 |
# File 'lib/ovirtsdk4/services.rb', line 18347 def volume_types_service @volume_types_service ||= OpenstackVolumeTypesService.new(self, 'volumetypes') end |