utils

package
v0.0.16 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLoadBalancerNameFromDNSName

func GetLoadBalancerNameFromDNSName(dnsName string) string

GetLoadBalancerNameFromDNSName gets the name of load balancer from DNS name by splitting the dnsName on '-'

func GetLoadBalancerNames added in v0.0.14

func GetLoadBalancerNames(filter config.Filter, clientSet clientset.Interface) []string

Get Load Balancer names

func IsEc2IpPermissionEqual

func IsEc2IpPermissionEqual(ipPermission1 *ec2.IpPermission, ipPermission2 *ec2.IpPermission) bool

IsEc2IpPermissionEqual Compares two ec2 ips to check if they are equal

func IsEc2IpRangeEqual

func IsEc2IpRangeEqual(ipRanges1 []*ec2.IpRange, ipRanges2 []*ec2.IpRange) bool

IsEc2IpRangeEqual comparese to ec2.ipRanges to check if they are equal

func IsEc2Ipv6RangeEqual

func IsEc2Ipv6RangeEqual(ipv6Ranges1 []*ec2.Ipv6Range, ipv6Ranges2 []*ec2.Ipv6Range) bool

IsEc2Ipv6RangeEqual comparese to ec2.ipv6Ranges to check if they are equal

func IsInt64Equal

func IsInt64Equal(val1 *int64, val2 *int64) bool

IsInt64Equal Compares two int64 pointers with checks for null pointers

func IsStringEqual

func IsStringEqual(val1 *string, val2 *string) bool

IsStringEqual Compares two String pointers with checks for null pointers

Types

type IpPermission

type IpPermission struct {
	IpRanges   []*IpRange `yaml:"ipRanges"`
	FromPort   *int64     `yaml:"fromPort"`
	ToPort     *int64     `yaml:"toPort"`
	IpProtocol *string    `yaml:"ipProtocol"`
}

func CombineIpPermission

func CombineIpPermission(ipPermissions []IpPermission, permissionsToAdd []IpPermission) []IpPermission

CombineIpPermission merges permissions into existing permissions with same port and protocol

func (*IpPermission) Equal

func (ipPermission1 *IpPermission) Equal(ipPermission2 *IpPermission) bool

type IpRange

type IpRange struct {
	IpCidr      *string `yaml:"ipCidr"`
	Description *string `yaml:"description"`
}

func (*IpRange) Equal

func (ipRange1 *IpRange) Equal(ipRange2 *IpRange) bool

Equal compares IPRanges

Jump to

Keyboard shortcuts

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