ipwhitelist

package
v0.0.0-...-ca852fc Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2017 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrMissingWhitelist returned error when the ingress does not contains the
	// whitelist annotation
	ErrMissingWhitelist = errors.New("whitelist annotation is missing")

	// ErrInvalidCIDR returned error when the whitelist annotation does not
	// contains a valid IP or network address
	ErrInvalidCIDR = errors.New("the annotation does not contains a valid IP address or network")
)

Functions

This section is empty.

Types

type SourceRange

type SourceRange struct {
	CIDR []string
}

SourceRange returns the CIDR

func ParseAnnotations

func ParseAnnotations(whiteList []string, ing *extensions.Ingress) (*SourceRange, error)

ParseAnnotations parses the annotations contained in the ingress rule used to limit access to certain client addresses or networks. Multiple ranges can specified using commas as separator e.g. `18.0.0.0/8,56.0.0.0/8`

Jump to

Keyboard shortcuts

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