Class: OvirtSDK4::OpenstackImageProviderService
- Inherits:
-
ExternalProviderService
- Object
- Service
- ExternalProviderService
- OvirtSDK4::OpenstackImageProviderService
- Defined in:
- lib/ovirtsdk4/services.rb,
lib/ovirtsdk4/services.rb
Instance Method Summary collapse
-
#certificates_service ⇒ ExternalProviderCertificatesService
A service to view certificates for this external provider.
-
#get(opts = {}) ⇒ OpenStackImageProvider
Returns the representation of the object managed by this service.
-
#images_service ⇒ OpenstackImagesService
Locates the
images
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 = {}) ⇒ OpenStackImageProvider
Update the specified OpenStack image provider in the system.
Methods inherited from Service
Instance Method Details
#certificates_service ⇒ ExternalProviderCertificatesService
A service to view certificates for this external provider.
15838 15839 15840 |
# File 'lib/ovirtsdk4/services.rb', line 15838 def certificates_service @certificates_service ||= ExternalProviderCertificatesService.new(self, 'certificates') end |
#get(opts = {}) ⇒ OpenStackImageProvider
Returns the representation of the object managed by this service.
15717 15718 15719 |
# File 'lib/ovirtsdk4/services.rb', line 15717 def get(opts = {}) internal_get(GET, opts) end |
#images_service ⇒ OpenstackImagesService
Locates the images
service.
15847 15848 15849 |
# File 'lib/ovirtsdk4/services.rb', line 15847 def images_service @images_service ||= OpenstackImagesService.new(self, 'images') end |
#import_certificates(opts = {}) ⇒ Object
Import the SSL certificates of the external host provider.
15743 15744 15745 |
# File 'lib/ovirtsdk4/services.rb', line 15743 def import_certificates(opts = {}) internal_action(:importcertificates, nil, IMPORT_CERTIFICATES, opts) end |
#remove(opts = {}) ⇒ Object
Deletes the object managed by this service.
15768 15769 15770 |
# File 'lib/ovirtsdk4/services.rb', line 15768 def remove(opts = {}) internal_remove(REMOVE, opts) end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
15858 15859 15860 15861 15862 15863 15864 15865 15866 15867 15868 15869 15870 15871 15872 15873 15874 15875 |
# File 'lib/ovirtsdk4/services.rb', line 15858 def service(path) if path.nil? || path == '' return self end if path == 'certificates' return certificates_service end if path.start_with?('certificates/') return certificates_service.service(path[13..-1]) end if path == 'images' return images_service end if path.start_with?('images/') return images_service.service(path[7..-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
15800 15801 15802 |
# File 'lib/ovirtsdk4/services.rb', line 15800 def test_connectivity(opts = {}) internal_action(:testconnectivity, nil, TEST_CONNECTIVITY, opts) end |
#update(provider, opts = {}) ⇒ OpenStackImageProvider
Update the specified OpenStack image provider in the system.
15829 15830 15831 |
# File 'lib/ovirtsdk4/services.rb', line 15829 def update(provider, opts = {}) internal_update(provider, OpenStackImageProvider, UPDATE, opts) end |