Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type NotifierFunc ¶
NotifierFunc can be used to control notifications for failed status checks. Provided for static type checking.
func SlackNotifier ¶
func SlackNotifier(token, channel string, opts ...slack.MsgOption) NotifierFunc
SlackNotifier returns a NotifierFunc for slack using the provided token. An invalid token will result in an error during CheckStatus. Channel may be either a channel name or channel ID, like token if this is invalid it will result in an error during CheckStatus.
type Ping ¶
type Ping struct {
Addr url.URL
Status bool
NotifierFunc NotifierFunc
}
func (*Ping) CheckStatus ¶
CheckStatus should be called to initiating a status check on the provided address. If the optional NotifierFunc is set this will be executed. If no NotfierFunc is set the returned error will always be nil.
