client

package
v0.0.0-...-31a1246 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2018 License: BSD-3-Clause Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	STATUS_SYNCHRONIZING = "SYNCHRONIZING"
	STATUS_PENDING       = "PENDING"
	STATUS_OK            = "OK"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BackendPoolProperties

type BackendPoolProperties struct {
	HcPath       string `json:"hcPath"`
	HcBody       string `json:"hcBody"`
	HcStatusCode string `json:"hcStatusCode"`
}

type ErrAmbiguousSearch

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

func (ErrAmbiguousSearch) Error

func (e ErrAmbiguousSearch) Error() string

type ErrItemAlreadyExists

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

func (ErrItemAlreadyExists) Error

func (e ErrItemAlreadyExists) Error() string

type ErrItemNotFound

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

func (ErrItemNotFound) Error

func (e ErrItemNotFound) Error() string

type GalebClient

type GalebClient struct {
	ApiURL        string
	Username      string
	Password      string
	TokenHeader   string
	Environment   string
	Project       string
	BalancePolicy string
	RuleType      string
	WaitTimeout   time.Duration
	UseToken      bool
	Debug         bool
	// contains filtered or unexported fields
}

func (*GalebClient) AddBackend

func (c *GalebClient) AddBackend(backend *url.URL, poolName string) (string, error)

func (*GalebClient) AddBackendPool

func (c *GalebClient) AddBackendPool(name string) (string, error)

func (*GalebClient) AddBackends

func (c *GalebClient) AddBackends(backends []*url.URL, poolName string) error

func (*GalebClient) AddRuleToID

func (c *GalebClient) AddRuleToID(name, poolID string) (string, error)

func (*GalebClient) AddVirtualHost

func (c *GalebClient) AddVirtualHost(addr string) (string, error)

func (*GalebClient) FindTargetsByParent

func (c *GalebClient) FindTargetsByParent(poolName string) ([]Target, error)

func (*GalebClient) FindVirtualHostsByRule

func (c *GalebClient) FindVirtualHostsByRule(ruleName string) ([]VirtualHost, error)

func (*GalebClient) Healthcheck

func (c *GalebClient) Healthcheck() error

func (*GalebClient) RemoveBackendByID

func (c *GalebClient) RemoveBackendByID(backendID string) error

func (*GalebClient) RemoveBackendPool

func (c *GalebClient) RemoveBackendPool(poolName string) error

func (*GalebClient) RemoveBackendsByIDs

func (c *GalebClient) RemoveBackendsByIDs(backendIDs []string) error

func (*GalebClient) RemoveRule

func (c *GalebClient) RemoveRule(ruleName string) error

func (*GalebClient) RemoveRuleVirtualHost

func (c *GalebClient) RemoveRuleVirtualHost(ruleName, virtualHostName string) error

func (*GalebClient) RemoveRuleVirtualHostByID

func (c *GalebClient) RemoveRuleVirtualHostByID(ruleID, virtualHostID string) error

func (*GalebClient) RemoveVirtualHost

func (c *GalebClient) RemoveVirtualHost(virtualHostName string) error

func (*GalebClient) RemoveVirtualHostByID

func (c *GalebClient) RemoveVirtualHostByID(virtualHostID string) error

func (*GalebClient) SetRuleVirtualHost

func (c *GalebClient) SetRuleVirtualHost(ruleName, virtualHostName string) error

func (*GalebClient) SetRuleVirtualHostIDs

func (c *GalebClient) SetRuleVirtualHostIDs(ruleID, virtualHostID string) error

func (*GalebClient) UpdatePoolProperties

func (c *GalebClient) UpdatePoolProperties(poolName string, properties BackendPoolProperties) error

type Pool

type Pool struct {
	Project       string                `json:"project"`
	Environment   string                `json:"environment"`
	BalancePolicy string                `json:"balancePolicy"`
	Properties    BackendPoolProperties `json:"properties,omitempty"`
	// contains filtered or unexported fields
}

func (Pool) FullId

func (c Pool) FullId() string

func (Pool) GetName

func (c Pool) GetName() string

type Rule

type Rule struct {
	RuleType    string         `json:"ruleType,omitempty"`
	BackendPool string         `json:"pool,omitempty"`
	Default     bool           `json:"default,omitempty"`
	Order       int            `json:"order,omitempty"`
	Properties  RuleProperties `json:"properties,omitempty"`
	// contains filtered or unexported fields
}

func (Rule) FullId

func (c Rule) FullId() string

func (Rule) GetName

func (c Rule) GetName() string

type RuleProperties

type RuleProperties struct {
	Match string `json:"match"`
}

type Target

type Target struct {
	Project     string `json:"project"`
	Environment string `json:"environment"`
	BackendPool string `json:"parent,omitempty"`
	// contains filtered or unexported fields
}

func (Target) FullId

func (c Target) FullId() string

func (Target) GetName

func (c Target) GetName() string

type VirtualHost

type VirtualHost struct {
	Environment string `json:"environment,omitempty"`
	Project     string `json:"project,omitempty"`
	// contains filtered or unexported fields
}

func (VirtualHost) FullId

func (c VirtualHost) FullId() string

func (VirtualHost) GetName

func (c VirtualHost) GetName() string

Jump to

Keyboard shortcuts

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