mail

package
v0.1.0-beta Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Mail

type Mail struct {
	Host     string
	Port     string
	Username string
	Password string
	From     string
	To       []string
	Duration float64
	// contains filtered or unexported fields
}

Mail struct

func New

func New(host, port, password, username, from string, to []string, duration float64, status store.Status) *Mail

New returns a pointer to the instance of Mail Alert Struct

func (*Mail) Send

func (m *Mail) Send(subject, message string) error

Send sends the content

func (*Mail) Start

func (m *Mail) Start()

Start will start the listener on status updates and will send email notifications if needed

func (*Mail) Terminate

func (m *Mail) Terminate()

Terminate will gracefully shutdown the mail plugin

Jump to

Keyboard shortcuts

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