client

package
v1.4.0-alpha.1 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ProviderName = "nutanix"
)

Variables

View Source
var ErrPrismAddressNotSet = fmt.Errorf("cannot get credentials if Prism Address is not set")
View Source
var ErrPrismPortNotSet = fmt.Errorf("cannot get credentials if Prism Port is not set")

Functions

func GetCredentialRefForCluster

func GetCredentialRefForCluster(nutanixCluster *infrav1.NutanixCluster) (*credentialTypes.NutanixCredentialReference, error)

func GetTaskStatus added in v1.2.5

func GetTaskStatus(ctx context.Context, client *nutanixClientV3.Client, uuid string) (string, error)

func WaitForTaskToSucceed added in v1.2.5

func WaitForTaskToSucceed(ctx context.Context, conn *nutanixClientV3.Client, uuid string) error

WaitForTaskToSucceed will poll indefinitely every 2 seconds for the task with uuid to have status of "SUCCEEDED". The polling will not stop if the ctx is cancelled, it's only used for HTTP requests in the client. WaitForTaskToSucceed will exit immediately on an error getting the task.

Types

type NutanixClientHelper added in v0.5.2

type NutanixClientHelper struct {
	// contains filtered or unexported fields
}

func NewNutanixClientHelper added in v0.5.2

func NewNutanixClientHelper(secretInformer coreinformers.SecretInformer, cmInformer coreinformers.ConfigMapInformer) (*NutanixClientHelper, error)

func (*NutanixClientHelper) GetClient added in v0.5.2

func (n *NutanixClientHelper) GetClient(cred prismgoclient.Credentials, additionalTrustBundle string) (*nutanixClientV3.Client, error)

func (*NutanixClientHelper) GetClientFromEnvironment added in v0.5.2

func (n *NutanixClientHelper) GetClientFromEnvironment(ctx context.Context, nutanixCluster *infrav1.NutanixCluster) (*nutanixClientV3.Client, error)

Jump to

Keyboard shortcuts

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