kubefinder

package
v0.0.0-...-b5acc33 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	IstioCanonicalNameLabelKey = "service.istio.io/canonical-name"
)

Variables

View Source
var ErrFoundMoreThanOnePod = errors.Errorf("ip belongs to more than one pod")
View Source
var ErrFoundMoreThanOneService = errors.Errorf("ip belongs to more than one service")
View Source
var ErrNoPodFound = errors.Errorf("no pod found")

Functions

This section is empty.

Types

type KubeFinder

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

func NewKubeFinder

func NewKubeFinder(ctx context.Context, mgr manager.Manager) (*KubeFinder, error)

func (*KubeFinder) IsExternalIP

func (k *KubeFinder) IsExternalIP(ctx context.Context, ip string) (bool, error)

func (*KubeFinder) ResolveIPToExternalAccessService

func (k *KubeFinder) ResolveIPToExternalAccessService(ctx context.Context, ip string, port int) (*corev1.Service, bool, error)

func (*KubeFinder) ResolveIPToPod

func (k *KubeFinder) ResolveIPToPod(ctx context.Context, ip string) (*corev1.Pod, error)

func (*KubeFinder) ResolveIPToService

func (k *KubeFinder) ResolveIPToService(ctx context.Context, ip string) (*corev1.Service, bool, error)

func (*KubeFinder) ResolveIstioWorkloadToPod

func (k *KubeFinder) ResolveIstioWorkloadToPod(ctx context.Context, workload string, namespace string) (*corev1.Pod, error)

func (*KubeFinder) ResolvePodByName

func (k *KubeFinder) ResolvePodByName(ctx context.Context, name string, namespace string) (*corev1.Pod, error)

func (*KubeFinder) ResolveServiceAddressToIps

func (k *KubeFinder) ResolveServiceAddressToIps(ctx context.Context, fqdn string) ([]string, types.NamespacedName, error)

func (*KubeFinder) ResolveServiceToPods

func (k *KubeFinder) ResolveServiceToPods(ctx context.Context, svc *corev1.Service) ([]corev1.Pod, error)

Jump to

Keyboard shortcuts

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