inject

package
v2.3.12 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2025 License: MIT Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddContainer

func AddContainer(spec *corev1.PodSpec, c util.PodRouteConfig)

func AddEnvoyContainer added in v2.3.10

func AddEnvoyContainer(spec *v1.PodTemplateSpec, nodeId string, ipv6 bool)

func AddMeshContainer

func AddMeshContainer(spec *v1.PodTemplateSpec, nodeId string, c util.PodRouteConfig, ipv6 bool)

AddMeshContainer todo envoy support ipv6

func CleanupUselessInfo

func CleanupUselessInfo(pod *v1.Pod)

func CreateAfterDeletePod

func CreateAfterDeletePod(factory util.Factory, p *v1.Pod, helper *resource.Helper) error

func GetPort added in v2.3.10

func GetPort(templateSpec *v1.PodTemplateSpec, portMaps []string) ([]v1.ContainerPort, map[int32]string)

func InjectEnvoySidecar added in v2.3.10

func InjectEnvoySidecar(ctx context.Context, f cmdutil.Factory, clientset *kubernetes.Clientset, namespace, workload string, object *runtimeresource.Info, headers map[string]string, portMap []string) (err error)

InjectEnvoySidecar patch a sidecar, using iptables to do port-forward let this pod decide should go to 233.254.254.100 or request to 127.0.0.1 https://istio.io/latest/docs/ops/deployment/requirements/#ports-used-by-istio

func InjectVPNAndEnvoySidecar

func InjectVPNAndEnvoySidecar(ctx context.Context, f cmdutil.Factory, clientset v12.ConfigMapInterface, namespace, workload string, object *runtimeresource.Info, c util.PodRouteConfig, headers map[string]string, portMaps []string) (err error)

InjectVPNAndEnvoySidecar patch a sidecar, using iptables to do port-forward let this pod decide should go to 233.254.254.100 or request to 127.0.0.1

func InjectVPNSidecar

func InjectVPNSidecar(ctx context.Context, f util.Factory, namespace, workload string, object *resource.Info, c util2.PodRouteConfig) error

func ModifyServiceTargetPort added in v2.3.10

func ModifyServiceTargetPort(ctx context.Context, clientset *kubernetes.Clientset, namespace string, podLabels map[string]string, m map[int32]int32) error

func RemoveContainer

func RemoveContainer(spec *corev1.PodSpec)

func RemoveContainers

func RemoveContainers(spec *v1.PodTemplateSpec)

func UnPatchContainer

func UnPatchContainer(factory cmdutil.Factory, mapInterface v12.ConfigMapInterface, object *runtimeresource.Info, isMeFunc func(isFargateMode bool, rule *controlplane.Rule) bool) error

Types

type P

type P struct {
	Op    string      `json:"op,omitempty"`
	Path  string      `json:"path,omitempty"`
	Value interface{} `json:"value,omitempty"`
}

Jump to

Keyboard shortcuts

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