source

package
v1.35.5 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewFile

func NewFile(name string, spec v1alpha1.FileSpec) impl.LogSource

func NewKubernetes

func NewKubernetes(name string, spec v1alpha1.KubernetesPodsSpec, namespaced bool) impl.LogSource

Types

type File

type File struct {
	Exclude   []string `json:"exclude,omitempty"`
	Include   []string `json:"include,omitempty"`
	Delimiter string   `json:"line_delimiter,omitempty"`
	// contains filtered or unexported fields
}

File represents `file` vector source https://vector.dev/docs/reference/configuration/sources/file/

func (File) BuildSources

func (f File) BuildSources() []impl.LogSource

func (File) GetName

func (cs File) GetName() string

type Kubernetes

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

Kubernetes represents `kubernetes_logs` vector source https://vector.dev/docs/reference/configuration/sources/kubernetes_logs/

func (Kubernetes) BuildSources

func (k Kubernetes) BuildSources() []impl.LogSource

BuildSources denormalizes sources for vector config, which can handle only one namespace per source (it is impossible to use OR clauses for the field-selector, so you can only select a single namespace)

Also mutates name of the source: 1. Namespaced - d8_namespaced_<ns>_<source_name> 2. Cluster - d8_cluster_<ns>_<source_name> 3. Cluster with NamespaceSelector - d8_clusterns_<ns>_<source_name>

func (Kubernetes) GetName

func (cs Kubernetes) GetName() string

func (Kubernetes) MarshalJSON

func (k Kubernetes) MarshalJSON() ([]byte, error)

type KubernetesAnnotationFields

type KubernetesAnnotationFields struct {
	ContainerImage string `json:"container_image,omitempty"`
	ContainerName  string `json:"container_name,omitempty"`
	PodIP          string `json:"pod_ip,omitempty"`
	PodLabels      string `json:"pod_labels,omitempty"`
	PodName        string `json:"pod_name,omitempty"`
	PodNamespace   string `json:"pod_namespace,omitempty"`
	PodNodeName    string `json:"pod_node_name,omitempty"`
	PodOwner       string `json:"pod_owner,omitempty"`
}

KubernetesAnnotationFields are supported fields for the following vector options https://vector.dev/docs/reference/configuration/sources/kubernetes_logs/#pod_annotation_fields

Jump to

Keyboard shortcuts

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