config

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Version            string
	DaemonGitBuild     string
	DaemonGitBuildDate string
)

Version information (will be populated at build time using ldflags)

Functions

This section is empty.

Types

type APIConfig

type APIConfig struct {
	Enabled  bool
	Endpoint string
	APIKey   string
}

type Config

type Config struct {
	SMTP     SMTPConfig
	Telegram TelegramConfig
	API      APIConfig
	Debug    DebugConfig
	RabbitMQ RabbitMQConfig
	Slack    SlackConfig
}

func LoadConfig

func LoadConfig(filePath string) (*Config, error)

LoadConfig carga el archivo parsewatchdog.conf

type DebugConfig

type DebugConfig struct {
	DebugLevel int
}

type RabbitMQConfig

type RabbitMQConfig struct {
	Enabled  bool
	Type     string
	User     string
	Password string
	IP       string
	Port     int
	Queue    string
}

type SMTPConfig

type SMTPConfig struct {
	Enabled    bool
	Host       string
	Port       int
	User       string
	Pass       string
	Recipients []string
}

type SlackConfig

type SlackConfig struct {
	Enabled    bool
	WebhookURL string
}

type TelegramConfig

type TelegramConfig struct {
	Enabled bool
	Token   string
	ChatID  int64
}

Jump to

Keyboard shortcuts

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