resources

package
v0.0.0-...-b4d8713 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2017 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MasterIPAttempts specifies how many times are allowed to be taken to get the master node IP.
	MasterIPAttempts = 40
	// MasterIPSleepSecondsPerAttempt specifies how much time should pass after a failed attempt to get the master IP.
	MasterIPSleepSecondsPerAttempt = 3
	// DeleteAttempts specifies the amount of retries are allowed when trying to delete instance templates.
	DeleteAttempts = 150
	// RetrySleepSeconds specifies the time to sleep after a failed attempt to delete instance templates.
	DeleteSleepSeconds = 5
)

Variables

Sdk represents the connection to the google cloud SDK

Functions

This section is empty.

Types

type InstanceGroup

type InstanceGroup struct {
	Shared
	Location         string
	Size             string
	Image            string
	Count            int
	SSHFingerprint   string
	BootstrapScripts []string
	ServerPool       *cluster.ServerPool
}

InstanceGroup is a representation of the server to be created on the cloud provider.

func (*InstanceGroup) Actual

func (r *InstanceGroup) Actual(immutable *cluster.Cluster) (*cluster.Cluster, cloud.Resource, error)

Actual is used to build a cluster based on instances on the cloud provider.

func (*InstanceGroup) Apply

func (r *InstanceGroup) Apply(actual, expected cloud.Resource, immutable *cluster.Cluster) (*cluster.Cluster, cloud.Resource, error)

Apply is used to create the expected resources on the cloud provider.

func (*InstanceGroup) Delete

func (r *InstanceGroup) Delete(actual cloud.Resource, immutable *cluster.Cluster) (*cluster.Cluster, cloud.Resource, error)

Delete is used to delete the instances on the cloud provider

func (*InstanceGroup) Expected

func (r *InstanceGroup) Expected(immutable *cluster.Cluster) (*cluster.Cluster, cloud.Resource, error)

Expected is used to build a cluster expected to be on the cloud provider.

type Shared

type Shared struct {
	CloudID        string
	Name           string
	LabelResource  cloud.Resource
	CachedActual   cloud.Resource
	CachedExpected cloud.Resource
}

Todo add description

Jump to

Keyboard shortcuts

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