ocm

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2021 License: Apache-2.0 Imports: 16 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAddOn

func GetAddOn(client *cmv1.AddOnsClient, id string) (*cmv1.AddOn, error)

func GetAvailableAddOns

func GetAvailableAddOns(connection *sdk.Connection) ([]*cmv1.AddOn, error)

Get complete list of available add-ons for the current organization

func GetCluster

func GetCluster(client *cmv1.ClustersClient, clusterKey string, creatorARN string) (*cmv1.Cluster, error)

func GetClusterState

func GetClusterState(client *cmv1.ClustersClient, clusterID string) (cmv1.ClusterState, error)

func GetDefaultClusterFlavors

func GetDefaultClusterFlavors(ocmClient *cmv1.Client) (dMachinecidr *net.IPNet, dPodcidr *net.IPNet,
	dServicecidr *net.IPNet, dhostPrefix int)

func GetIdentityProviders

func GetIdentityProviders(client *cmv1.ClustersClient, clusterID string) ([]*cmv1.IdentityProvider, error)

func GetIngresses

func GetIngresses(client *cmv1.ClustersClient, clusterID string) ([]*cmv1.Ingress, error)

func GetInstallLogs

func GetInstallLogs(client *cmv1.ClustersClient, clusterID string, tail int) (logs *cmv1.Log, err error)

func GetMachinePools

func GetMachinePools(client *cmv1.ClustersClient, clusterID string) ([]*cmv1.MachinePool, error)

func GetUninstallLogs

func GetUninstallLogs(client *cmv1.ClustersClient, clusterID string, tail int) (logs *cmv1.Log, err error)

func GetUser

func GetUser(client *cmv1.ClustersClient, clusterID string, group string, username string) (*cmv1.User, error)

func GetUsers

func GetUsers(client *cmv1.ClustersClient, clusterID string, group string) ([]*cmv1.User, error)

func HasClusters

func HasClusters(client *cmv1.ClustersClient, creatorARN string) (bool, error)

func IdentityProviderType

func IdentityProviderType(idp *cmv1.IdentityProvider) string

func IsValidClusterKey

func IsValidClusterKey(clusterKey string) bool

func IsValidUsername

func IsValidUsername(username string) bool

func PollInstallLogs

func PollInstallLogs(client *cmv1.ClustersClient, clusterID string,
	cb func(*cmv1.LogGetResponse) bool) (logs *cmv1.Log, err error)

func PollUninstallLogs

func PollUninstallLogs(client *cmv1.ClustersClient, clusterID string,
	cb func(*cmv1.LogGetResponse) bool) (logs *cmv1.Log, err error)

Types

type ClusterAddOn

type ClusterAddOn struct {
	ID    string
	Name  string
	State string
}

func GetClusterAddOns

func GetClusterAddOns(connection *sdk.Connection, clusterID string) ([]*ClusterAddOn, error)

Get all add-ons available for a cluster

type ConnectionBuilder

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

ConnectionBuilder contains the information and logic needed to build a connection to OCM. Don't create instances of this type directly; use the NewConnection function instead.

func NewConnection

func NewConnection() *ConnectionBuilder

NewConnection creates a builder that can then be used to configure and build an OCM connection. Don't create instances of this type directly; use the NewConnection function instead.

func (*ConnectionBuilder) Build

func (b *ConnectionBuilder) Build() (result *sdk.Connection, err error)

Build uses the information stored in the builder to create a new OCM connection.

func (*ConnectionBuilder) Config

func (b *ConnectionBuilder) Config(value *config.Config) *ConnectionBuilder

Config sets the configuration that the connection will use to authenticate the user

func (*ConnectionBuilder) Logger

func (b *ConnectionBuilder) Logger(value *logrus.Logger) *ConnectionBuilder

Logger sets the logger that the connection will use to send messages to the log. This is mandatory.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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