tracingpolicy

package
v0.12.0-pre.0 Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GenericTracingPolicy added in v0.10.0

type GenericTracingPolicy struct {
	ApiVersion string                     `json:"apiVersion"`
	Kind       string                     `json:"kind"`
	Metadata   Metadata                   `json:"metadata"`
	Spec       v1alpha1.TracingPolicySpec `json:"spec"`
}

func (*GenericTracingPolicy) TpInfo added in v0.10.0

func (gtp *GenericTracingPolicy) TpInfo() string

func (*GenericTracingPolicy) TpName added in v0.10.0

func (gtp *GenericTracingPolicy) TpName() string

func (*GenericTracingPolicy) TpSpec added in v0.10.0

type GenericTracingPolicyNamespaced added in v0.10.0

type GenericTracingPolicyNamespaced struct {
	ApiVersion string                     `json:"apiVersion"`
	Kind       string                     `json:"kind"`
	Metadata   MetadataNamespaced         `json:"metadata"`
	Spec       v1alpha1.TracingPolicySpec `json:"spec"`
}

func (*GenericTracingPolicyNamespaced) TpInfo added in v0.10.0

func (gtp *GenericTracingPolicyNamespaced) TpInfo() string

func (*GenericTracingPolicyNamespaced) TpName added in v0.10.0

func (gtp *GenericTracingPolicyNamespaced) TpName() string

func (*GenericTracingPolicyNamespaced) TpNamespace added in v0.10.0

func (gtp *GenericTracingPolicyNamespaced) TpNamespace() string

func (*GenericTracingPolicyNamespaced) TpSpec added in v0.10.0

type Metadata added in v0.10.0

type Metadata struct {
	Name              string            `json:"name"`
	Annotations       map[string]string `json:"annotations"`
	CreationTimestamp time.Time         `json:"creationTimestamp,omitempty"`
}

type MetadataNamespaced added in v0.10.0

type MetadataNamespaced struct {
	Name        string            `yaml:"name"`
	Namespace   string            `yaml:"namespace"`
	Annotations map[string]string `yaml:"annotations"`
}

type PolicyEvent added in v0.10.0

type PolicyEvent interface {
	PolicyInfo() PolicyInfo
}

type PolicyInfo added in v0.10.0

type PolicyInfo struct {
	Name string
	Hook string
}

type TracingPolicy

type TracingPolicy interface {
	// TpName returns the name of the policy.
	TpName() string
	// TpSpec  returns the specification of the policy
	TpSpec() *v1alpha1.TracingPolicySpec
	// TpInfo returns a description of the policy
	TpInfo() string
}

TracingPolicy is a tracing policy interface. It is implemented by v1alpha1.types.TracingPolicy and config.GenericTracingConf. The former is what is the k8s API server uses, and the latter is used when we load files directly (e.g., via the cli).

func NamespacedPolicyFromYAML added in v0.10.0

func NamespacedPolicyFromYAML(data string) (TracingPolicy, error)

func PolicyFromYAML added in v0.10.0

func PolicyFromYAML(data string) (TracingPolicy, error)

func PolicyFromYAMLFilename added in v0.10.0

func PolicyFromYAMLFilename(fileName string) (TracingPolicy, error)

type TracingPolicyNamespaced

type TracingPolicyNamespaced interface {
	TracingPolicy
	// TpNamespace returns the namespace of the policy
	TpNamespace() string
}

TracingPolicyNamespaced is an interface for tracing policy applied on a specific namespace

Directories

Path Synopsis
SPDX-License-Identifier: Apache-2.0 Copyright Authors of Tetragon
SPDX-License-Identifier: Apache-2.0 Copyright Authors of Tetragon

Jump to

Keyboard shortcuts

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