daemon

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: May 22, 2025 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultConfigPath = "./config.yml"

DefaultConfigPath specifies the default location of Icinga for Kubernetes's config.yml if not set via command line flag.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Database      database.Config          `yaml:"database" envPrefix:"DATABASE_"`
	Logging       logging.Config           `yaml:"logging" envPrefix:"LOGGING_"`
	Notifications notifications.Config     `yaml:"notifications" envPrefix:"NOTIFICATIONS_"`
	Prometheus    metrics.PrometheusConfig `yaml:"prometheus" envPrefix:"PROMETHEUS_"`
}

Config defines Icinga Kubernetes config.

func (*Config) Validate

func (c *Config) Validate() error

Validate checks constraints in the supplied configuration and returns an error if they are violated.

type ConfigFlagGlue

type ConfigFlagGlue struct {
	// Config is the path to the config file
	Config string
}

ConfigFlagGlue provides a glue struct for the CLI config flag.

ConfigFlagGlue implements the github.com/icinga/icinga-go-library/config.Flags interface.

func (ConfigFlagGlue) GetConfigPath

func (f ConfigFlagGlue) GetConfigPath() string

GetConfigPath retrieves the path to the configuration file. It returns the path specified via the command line, or DefaultConfigPath if none is provided.

func (ConfigFlagGlue) IsExplicitConfigPath

func (f ConfigFlagGlue) IsExplicitConfigPath() bool

IsExplicitConfigPath indicates whether the configuration file path was explicitly set.

Jump to

Keyboard shortcuts

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