kube

package
v0.0.0-...-4fbd946 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2019 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	BlockingIndexTerminated = errors.New("blocking index terminated")
)

Functions

func IamRoleFromServiceAccount

func IamRoleFromServiceAccount(svcAcc *core_v1.ServiceAccount) (*iam4kube.IamRole, error)

Types

type BlockingIndex

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

func NewBlockingGetByIndex

func NewBlockingGetByIndex(informer cache.SharedIndexInformer, indexFunc cache.IndexFunc) (*BlockingIndex, error)

func NewBlockingGetByKey

func NewBlockingGetByKey(informer cache.SharedIndexInformer) *BlockingIndex

func NewBlockingIndex

func NewBlockingIndex(informer cache.SharedIndexInformer, lookupFunc LookupFunc) *BlockingIndex

func (*BlockingIndex) Get

func (b *BlockingIndex) Get(ctx context.Context, key string) ([]interface{}, error)

func (*BlockingIndex) Run

func (b *BlockingIndex) Run(ctx context.Context)

type Kroler

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

func NewKroler

func NewKroler(logger *zap.Logger, podsInf, svcAccInf cache.SharedIndexInformer) (*Kroler, error)

func (*Kroler) RoleForIp

func (k *Kroler) RoleForIp(ctx context.Context, ip iam4kube.IP) (*core_v1.Pod, *iam4kube.IamRole, error)

RoleForIp fetches the IAM role that is supposed to be used by a Pod with the provided IP. Returns nil if no IAM role is assigned. May return non-nil pod even on error.

func (*Kroler) Run

func (k *Kroler) Run(ctx context.Context)

type LookupFunc

type LookupFunc func(key string) ([]interface{}, error)

Jump to

Keyboard shortcuts

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