gce

package
v0.0.0-...-1bd2c38 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GCEClient

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

GCEClient is a placeholder for GCE stuff.

func CreateGCECloud

func CreateGCECloud(project string, network string) (*GCEClient, error)

CreateGCECloud creates a new instance of GCECloud.

func (*GCEClient) AddInstanceToTargetPool

func (gce *GCEClient) AddInstanceToTargetPool(region, name string, toAdd []*compute.InstanceReference) error

AddInstanceToTargetPool adds instances to the targetpool

func (*GCEClient) AddInstancesToInstanceGroup

func (gce *GCEClient) AddInstancesToInstanceGroup(name, zone string, instances []*compute.InstanceReference) error

AddInstancesToInstanceGroup adds given instance to an Instance Group

func (*GCEClient) CreateBackendService

func (gce *GCEClient) CreateBackendService(name string, port string, zones []string) error

CreateBackendService creates the given BackendService.

func (*GCEClient) CreateExternalIP

func (gce *GCEClient) CreateExternalIP(region, name string) (*compute.Address, error)

CreateExternalIP creates a new external IP to be used with LB

func (*GCEClient) CreateFirewall

func (gce *GCEClient) CreateFirewall(name string, network string, port string, tags []string) error

CreateFirewall creates a global firewall rule

func (*GCEClient) CreateForwardingRule

func (gce *GCEClient) CreateForwardingRule(region, name, address, port string) (*compute.ForwardingRule, error)

CreateForwardingRule creates and returns a GlobalForwardingRule that points to the given TargetHttpProxy.

func (*GCEClient) CreateHealthCheck

func (gce *GCEClient) CreateHealthCheck(name string, port string) error

CreateHealthCheck creates the given HttpHealthCheck.

func (*GCEClient) CreateInstanceGroup

func (gce *GCEClient) CreateInstanceGroup(project, zone, name string) (*compute.InstanceGroup, error)

CreateInstanceGroup returns an instance group by name

func (*GCEClient) CreateTargetPool

func (gce *GCEClient) CreateTargetPool(region, name string, instances []string) (*compute.TargetPool, error)

CreateTargetPool creates a targetpool

func (*GCEClient) DeleteInstanceFromTargetPool

func (gce *GCEClient) DeleteInstanceFromTargetPool(region, name string, toDel []*compute.InstanceReference) error

DeleteInstanceFromTargetPool deletes instances from the targetpool

func (*GCEClient) DeleteInstanceGroup

func (gce *GCEClient) DeleteInstanceGroup(project, zone, name string) error

DeleteInstanceGroup returns an instance group by name

func (*GCEClient) GetAvailableZones

func (gce *GCEClient) GetAvailableZones() (*compute.ZoneList, error)

GetAvailableZones returns all available zones for this project

func (*GCEClient) GetBackendService

func (gce *GCEClient) GetBackendService(name string) (*compute.BackendService, error)

GetBackendService retrieves a backend by name.

func (*GCEClient) GetExternalIP

func (gce *GCEClient) GetExternalIP(region, name string) (*compute.Address, error)

GetExternalIP confirms that the named External IP exists

func (*GCEClient) GetForwardingRule

func (gce *GCEClient) GetForwardingRule(region, name string) (*compute.ForwardingRule, error)

func (*GCEClient) GetHealthCheck

func (gce *GCEClient) GetHealthCheck(name, port string) (*compute.HealthCheck, error)

healthcheck management GetHealthCheck returns the given HttpHealthCheck by name.

func (*GCEClient) GetInstanceGroup

func (gce *GCEClient) GetInstanceGroup(project, zone, name string) (*compute.InstanceGroup, error)

GetInstanceGroup returns an instance group by name

func (*GCEClient) GetTargetPool

func (gce *GCEClient) GetTargetPool(region, name string) (*compute.TargetPool, error)

GetTargetPool gets the list of instances in a targetpool

func (*GCEClient) ListInstancesInInstanceGroupForZone

func (gce *GCEClient) ListInstancesInInstanceGroupForZone(name string, zone string) (*compute.InstanceGroupsListInstances, error)

ListInstancesInInstanceGroupForZone lists all the instances in a given instance group for the given zone.

func (*GCEClient) ListInstancesInZone

func (gce *GCEClient) ListInstancesInZone(zone string, tags, labels []string) (*compute.InstanceList, error)

ListInstancesInZone returns all instances in a zone

func (*GCEClient) ListZonesInRegion

func (gce *GCEClient) ListZonesInRegion(project, region string) ([]string, error)

ListZonesInRegion gets a list of zones in a given region

func (*GCEClient) RemoveBackendService

func (gce *GCEClient) RemoveBackendService(name string) error

RemoveBackendService deletes the given BackendService by name.

func (*GCEClient) RemoveExternalIP

func (gce *GCEClient) RemoveExternalIP(name, region string) error

RemoveExternalIP deletes the ExternalIP by name.

func (*GCEClient) RemoveFirewall

func (gce *GCEClient) RemoveFirewall(name string) error

RemoveFirewall removes a global firewall rule

func (*GCEClient) RemoveForwardingRule

func (gce *GCEClient) RemoveForwardingRule(name, region string) error

RemoveForwardingRule deletes the GlobalForwardingRule by name.

func (*GCEClient) RemoveHealthCheck

func (gce *GCEClient) RemoveHealthCheck(name string) error

RemoveHealthCheck deletes the given HttpHealthCheck by name.

func (*GCEClient) RemoveInstancesFromInstanceGroup

func (gce *GCEClient) RemoveInstancesFromInstanceGroup(name, zone string, instances []*compute.InstanceReference) error

RemoveInstancesFromInstanceGroup adds given instance to an Instance Group

func (*GCEClient) RemoveTargetPool

func (gce *GCEClient) RemoveTargetPool(name, region string) error

RemoveTargetPool deletes the TargetPool by name.

func (*GCEClient) UpdateBackendService

func (gce *GCEClient) UpdateBackendService(name string, port string, zones []string) error

UpdateBackendService applies the given BackendService as an update to an existing service.

func (*GCEClient) UpdateFirewall

func (gce *GCEClient) UpdateFirewall(name string, network string, port string, tags []string) error

UpdateFirewall updates a global firewall rule

func (*GCEClient) UpdateHealthCheck

func (gce *GCEClient) UpdateHealthCheck(name string, port string) error

UpdateHealthCheck applies the given HttpHealthCheck as an update.

Jump to

Keyboard shortcuts

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