Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var FS = afero.NewOsFs()
FS defines file system used to read and write configuration files
View Source
var New = func() *serve { promConfig := os.Getenv("ARG_CONFIG_FILE") if len(promConfig) == 0 { promConfig = "/etc/prometheus/prometheus.yml" } alertIfShortcutData = GetShortcuts() return &serve{ alerts: make(map[string]prometheus.Alert), scrapes: make(map[string]prometheus.Scrape), nodeLabels: make(map[string]map[string]string), configPath: promConfig, } }
New returns instance of the `serve` structure
Functions ¶
func GetShortcuts ¶
func GetShortcuts() map[string]AlertIfShortcut
GetShortcuts returns shortcuts from a YAML file
Types ¶
Click to show internal directories.
Click to hide internal directories.