podinformer

package
v0.0.0-...-37aef56 Latest Latest
Warning

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

Go to latest
Published: May 5, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package podinformer keeps track of pods with the containerIDs.

Equivalent information can be retrieved with: kubectl get pods -o=jsonpath='{.items[*].status.containerStatuses[*].containerID}'

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContainerInfo

type ContainerInfo struct {
	PodUID      string
	Namespace   string
	Podname     string
	Idx         int
	ContainerID string
	Deleted     bool
}

type PodInformer

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

func NewPodInformer

func NewPodInformer(podInformerChan chan ContainerInfo) (*PodInformer, error)

func (*PodInformer) GetContainerIDFromPod

func (p *PodInformer) GetContainerIDFromPod(namespace, podname string, containerIndex int) (string, error)

func (*PodInformer) GetPodFromContainerID

func (p *PodInformer) GetPodFromContainerID(containerID string) (info *ContainerInfo, err error)

func (*PodInformer) Run

func (p *PodInformer) Run(threadiness int, stopCh chan struct{})

func (*PodInformer) Stop

func (p *PodInformer) Stop()

Jump to

Keyboard shortcuts

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