config

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2021 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Namespace is the top-level configuration key that all system-probe settings are nested underneath
	Namespace = "system_probe_config"
)

Variables

This section is empty.

Functions

func ValidateSocketAddress

func ValidateSocketAddress(sockPath string) error

ValidateSocketAddress validates that the sysprobe socket config option is of the correct format.

Types

type Config

type Config struct {
	Enabled        bool
	EnabledModules map[ModuleName]struct{}

	// When the system-probe is enabled in a separate container, we need a way to also disable the system-probe
	// packaged in the main agent container (without disabling network collection on the process-agent).
	ExternalSystemProbe bool

	SocketAddress      string
	MaxConnsPerMessage int

	LogFile   string
	LogLevel  string
	DebugPort int

	StatsdHost string
	StatsdPort int

	// Settings for profiling, or nil if not enabled
	ProfilingSettings *profiling.Settings
}

Config represents the configuration options for the system-probe

func Merge

func Merge(configPath string) (*Config, error)

Merge will merge the system-probe configuration into the existing datadog configuration

func New

func New(configPath string) (*Config, error)

New creates a config object for system-probe. It assumes no configuration has been loaded as this point.

func (Config) ModuleIsEnabled

func (c Config) ModuleIsEnabled(modName ModuleName) bool

ModuleIsEnabled returns a bool indicating if the given module name is enabled.

type ModuleName

type ModuleName string

ModuleName is a typed alias for string, used only for module names

const (
	NetworkTracerModule        ModuleName = "network_tracer"
	OOMKillProbeModule         ModuleName = "oom_kill_probe"
	TCPQueueLengthTracerModule ModuleName = "tcp_queue_length_tracer"
	SecurityRuntimeModule      ModuleName = "security_runtime"
	ProcessModule              ModuleName = "process"
)

system-probe module names

Jump to

Keyboard shortcuts

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