clients

package
v0.0.0-...-d5be3fe Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 29, 2016 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package clients contains functions for creating OpenStack service clients for use in acceptance tests. It also manages the required environment variables to run the tests.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBlockStorageV1Client

func NewBlockStorageV1Client() (*gophercloud.ServiceClient, error)

NewBlockStorageV1Client returns a *ServiceClient for making calls to the OpenStack Block Storage v1 API. An error will be returned if authentication or client creation was not possible.

func NewBlockStorageV2Client

func NewBlockStorageV2Client() (*gophercloud.ServiceClient, error)

NewBlockStorageV2Client returns a *ServiceClient for making calls to the OpenStack Block Storage v2 API. An error will be returned if authentication or client creation was not possible.

func NewComputeV2Client

func NewComputeV2Client() (*gophercloud.ServiceClient, error)

NewComputeV2Client returns a *ServiceClient for making calls to the OpenStack Compute v2 API. An error will be returned if authentication or client creation was not possible.

func NewIdentityV2AdminClient

func NewIdentityV2AdminClient() (*gophercloud.ServiceClient, error)

NewIdentityV2AdminClient returns a *ServiceClient for making calls to the Admin Endpoint of the OpenStack Identity v2 API. An error will be returned if authentication or client creation was not possible.

func NewIdentityV2Client

func NewIdentityV2Client() (*gophercloud.ServiceClient, error)

NewIdentityV2Client returns a *ServiceClient for making calls to the OpenStack Identity v2 API. An error will be returned if authentication or client creation was not possible.

func NewIdentityV2UnauthenticatedClient

func NewIdentityV2UnauthenticatedClient() (*gophercloud.ServiceClient, error)

NewIdentityV2UnauthenticatedClient returns an unauthenticated *ServiceClient for the OpenStack Identity v2 API. An error will be returned if authentication or client creation was not possible.

func NewIdentityV3Client

func NewIdentityV3Client() (*gophercloud.ServiceClient, error)

NewIdentityV3Client returns a *ServiceClient for making calls to the OpenStack Identity v3 API. An error will be returned if authentication or client creation was not possible.

func NewIdentityV3UnauthenticatedClient

func NewIdentityV3UnauthenticatedClient() (*gophercloud.ServiceClient, error)

NewIdentityV3UnauthenticatedClient returns an unauthenticated *ServiceClient for the OpenStack Identity v3 API. An error will be returned if authentication or client creation was not possible.

Types

type AcceptanceTestChoices

type AcceptanceTestChoices struct {
	// ImageID contains the ID of a valid image.
	ImageID string

	// FlavorID contains the ID of a valid flavor.
	FlavorID string

	// FlavorIDResize contains the ID of a different flavor available on the same OpenStack installation, that is distinct
	// from FlavorID.
	FlavorIDResize string

	// FloatingIPPool contains the name of the pool from where to obtain floating IPs.
	FloatingIPPoolName string

	// NetworkName is the name of a network to launch the instance on.
	NetworkName string
}

AcceptanceTestChoices contains image and flavor selections for use by the acceptance tests.

func AcceptanceTestChoicesFromEnv

func AcceptanceTestChoicesFromEnv() (*AcceptanceTestChoices, error)

AcceptanceTestChoicesFromEnv populates a ComputeChoices struct from environment variables. If any required state is missing, an `error` will be returned that enumerates the missing properties.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL