alert

package
v0.0.0-...-aec2e1a Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2022 License: Unlicense Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Alert

type Alert interface {
	Init() error
	Send(subject, body, name string) error
}

func GetAlert

func GetAlert(cfg *config.Config) (Alert, error)

type EmailAlert

type EmailAlert struct {
	Host     string
	Port     int
	From     string
	Password string
	To       string
	Others   string
	Tos      []string
	CCs      []string

	Interval int64
}

func (*EmailAlert) Init

func (ep *EmailAlert) Init() error

func (*EmailAlert) Send

func (ep *EmailAlert) Send(subject, body, name string) error

Jump to

Keyboard shortcuts

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