Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ValidateConfig ¶
ValidateConfig validates the OCI Flexible Volume Provisioner config file.
Types ¶
type AuthConfig ¶
type AuthConfig struct { Region string `yaml:"region"` RegionKey string `yaml:"regionKey"` TenancyOCID string `yaml:"tenancy"` CompartmentOCID string `yaml:"compartment"` // DEPRECATED (we no longer directly use this) UserOCID string `yaml:"user"` PrivateKey string `yaml:"key"` Passphrase string `yaml:"passphrase"` PrivateKeyPassphrase string `yaml:"key_passphase"` // DEPRECATED Fingerprint string `yaml:"fingerprint"` VcnOCID string `yaml:"vcn"` }
AuthConfig holds the configuration required for communicating with the OCI API.
type Config ¶
type Config struct { Auth AuthConfig `yaml:"auth"` UseInstancePrincipals bool `yaml:"useInstancePrincipals"` // contains filtered or unexported fields }
Config holds the configuration for the OCI flexvolume driver.
func ConfigFromFile ¶
ConfigFromFile reads the file at the given path and marshals it into a Config object.
type Interface ¶
type Interface interface { // FindVolumeAttachment searches for a volume attachment in either the state // ATTACHING or ATTACHED and returns the first volume attachment found. FindVolumeAttachment(volumeID string) (core.VolumeAttachment, error) // WaitForVolumeAttached polls waiting for a OCI block volume to be in the // ATTACHED state. WaitForVolumeAttached(volumeAttachmentID string) (core.VolumeAttachment, error) // GetInstance retrieves the oci.Instance for a given OCID. GetInstance(id string) (*core.Instance, error) // AttachVolume attaches a block storage volume to the specified instance. // See https://docs.us-phoenix-1.oraclecloud.com/api/#/en/iaas/20160918/VolumeAttachment/AttachVolume AttachVolume(instanceID, volumeID string) (core.VolumeAttachment, int, error) // DetachVolume detaches a storage volume from the specified instance. // See: https://docs.us-phoenix-1.oraclecloud.com/api/#/en/iaas/20160918/Volume/DetachVolume DetachVolume(volumeAttachmentID string) error // WaitForVolumeDetached polls waiting for a OCI block volume to be in the // DETACHED state. WaitForVolumeDetached(volumeAttachmentID string) error // GetConfig returns the Config associated with the OCI API client. GetConfig() *Config }
Interface abstracts the OCI SDK and application specific convenience methods for interacting with the OCI API.
Click to show internal directories.
Click to hide internal directories.