gke

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DefaultScope used by the GKE API.
	DefaultScope = container.CloudPlatformScope
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	CreateCluster(string, computev1alpha1.GKEClusterSpec) (*container.Cluster, error)
	GetCluster(zone, name string) (*container.Cluster, error)
	DeleteCluster(zone, name string) error
}

Client interface to perform cluster operations

type ClusterClient

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

ClusterClient implementation

func NewClusterClient

func NewClusterClient(creds *google.Credentials) (*ClusterClient, error)

NewClusterClient return new instance of the Client based on credentials

func (*ClusterClient) CreateCluster

func (c *ClusterClient) CreateCluster(name string, spec computev1alpha1.GKEClusterSpec) (*container.Cluster, error)

CreateCluster creates a new GKE cluster.

func (*ClusterClient) DefaultKubernetesVersion

func (c *ClusterClient) DefaultKubernetesVersion(zone string) (string, error)

DefaultKubernetesVersion is the default Kubernetes Cluster version supported by GKE for given project/zone

func (*ClusterClient) DeleteCluster

func (c *ClusterClient) DeleteCluster(zone, name string) error

DeleteCluster in the given zone with the given name

func (*ClusterClient) GetCluster

func (c *ClusterClient) GetCluster(zone, name string) (*container.Cluster, error)

GetCluster retrieve GKE Cluster based on provided zone and name

Jump to

Keyboard shortcuts

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