Class: Kitchen::Driver::Oci::Api

Inherits:
Object
  • Object
show all
Defined in:
lib/kitchen/driver/oci/api.rb

Overview

Defines the various API classes used to interact with OCI.

Author:

  • Justin Steele <justin.steele@oracle.com>

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(oci_config, config) ⇒ Api

Returns a new instance of Api.



27
28
29
30
# File 'lib/kitchen/driver/oci/api.rb', line 27

def initialize(oci_config, config)
  @oci_config = oci_config
  @config = config
end

Instance Attribute Details

#configKitchen::LazyHash (readonly)

The config provided by the driver.

Returns:

  • (Kitchen::LazyHash)


40
41
42
# File 'lib/kitchen/driver/oci/api.rb', line 40

def config
  @config
end

#oci_configOCI::Config (readonly)

The config used to authenticate to OCI.

Returns:

  • (OCI::Config)


35
36
37
# File 'lib/kitchen/driver/oci/api.rb', line 35

def oci_config
  @oci_config
end

Instance Method Details

#blockstorageOCI::Core::BlockstorageClient

Creates a Blockstorage API client.

Returns:

  • (OCI::Core::BlockstorageClient)


73
74
75
# File 'lib/kitchen/driver/oci/api.rb', line 73

def blockstorage
  generic_api(OCI::Core::BlockstorageClient)
end

#computeOCI::Core::ComputeClient

Creates a Compute API client.

Returns:

  • (OCI::Core::ComputeClient)


45
46
47
# File 'lib/kitchen/driver/oci/api.rb', line 45

def compute
  generic_api(OCI::Core::ComputeClient)
end

#dbaasOCI::Core::DatabaseClient

Creates a Database API client.

Returns:

  • (OCI::Core::DatabaseClient)


59
60
61
# File 'lib/kitchen/driver/oci/api.rb', line 59

def dbaas
  generic_api(OCI::Database::DatabaseClient)
end

#identityOCI::Core::IdentityClient

Creates an Identity API client.

Returns:

  • (OCI::Core::IdentityClient)


66
67
68
# File 'lib/kitchen/driver/oci/api.rb', line 66

def identity
  generic_api(OCI::Identity::IdentityClient)
end

#networkOCI::Core::VirtualNetworkClient

Creates a Network API client.

Returns:

  • (OCI::Core::VirtualNetworkClient)


52
53
54
# File 'lib/kitchen/driver/oci/api.rb', line 52

def network
  generic_api(OCI::Core::VirtualNetworkClient)
end