loadbalancer

package
v0.8.7 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ValidChars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890-"

Functions

func CreateTargetGroupName

func CreateTargetGroupName(scope, name string) (string, error)

func GetListener

func GetListener(arn string, elb *elbv2.Client) (err error)

func GetLoadbalancer

func GetLoadbalancer(listenerArn string, elb *elbv2.Client) (loadbalancer string, err error)

func ValidateString

func ValidateString(s, alphabet string, min, max int) error

This might be a way to detailed way of handling validation

Types

type Listener

type Listener string

func CreateListener

func CreateListener(loadbalancer, cert string, elb *elbv2.Client) (listener Listener, err error)

func GetListeners

func GetListeners(loadbalancerARN string, elb *elbv2.Client) (l []Listener, err error)

func (Listener) GetHighestPriority

func (l Listener) GetHighestPriority(elb *elbv2.Client) (highestPri int, err error)

func (Listener) GetLoadbalancer

func (l Listener) GetLoadbalancer(elb *elbv2.Client) (loadbalancer string, err error)

func (Listener) GetNumRules

func (l Listener) GetNumRules(elb *elbv2.Client) (numRules int, err error)

type Loadbalancer

type Loadbalancer struct {
	ARN           string `json:"arn"`
	Name          string
	SecurityGroup string   `json:"security_group"`
	DNSName       string   `json:"dns_name"`
	ListenerARN   string   `json:"listener_arn"`
	Paths         []string `json:"paths"`
}

func CreateLoadbalancer

func CreateLoadbalancer(name, sg string, subnets []string, elb *elbv2.Client) (Loadbalancer, error)

func GetLoadbalancers

func GetLoadbalancers(svc *elbv2.Client) (loadbalancers []Loadbalancer, err error)

type Rule

type Rule struct {
	ARN string
	// contains filtered or unexported fields
}

func CreateRule

func CreateRule(l Listener, tg TargetGroup, elb *elbv2.Client) (r Rule, err error)

func GetRules

func GetRules(listenerARN string, elb *elbv2.Client) (r []Rule, err error)

func (*Rule) Delete

func (r *Rule) Delete(elb *elbv2.Client) (err error)

type Target

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

func CreateTarget

func CreateTarget(tg TargetGroup, s string, elb *elbv2.Client) (t Target, err error)

func (*Target) Delete

func (t *Target) Delete(elb *elbv2.Client) (err error)

type TargetGroup

type TargetGroup struct {
	Name    string `json:"name"`
	UriPath string `json:"path"`
	Port    int    `json:"port"`
	ARN     string `json:"arn"`
}

func CreateTargetGroup

func CreateTargetGroup(vpc, name, uriPath string, port int, elb *elbv2.Client) (TargetGroup, error)

func GetTargetGroup

func GetTargetGroup(name, uriPath string, port int, elb *elbv2.Client) (tg TargetGroup, err error)

func (*TargetGroup) Delete

func (tg *TargetGroup) Delete(elb *elbv2.Client) (err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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